In our latest series, we've explored how to leverage the Pdfcrowd cloud-based API for converting web pages and HTML files to PDF, previously using languages such as C and C++. As Rust offers a safer alternative to these languages, this article will guide you through integrating the Pdfcrowd HTML to PDF API into your Rust applications to achieve robust document conversion solutions. You can download the complete source code from GitHub.
PDFCrowd Blog
We have released version 2.15.0 of our Save as PDF WordPress plugin and 5.13.0 of our API client libraries.
New:
- Added a new option to specify which blank pages to remove from the output document.
HTML to PDF API: setRemoveBlankPages()
WP Plugin: Remove Blank Pages
In the previous article in this series we showed how to use the Pdfcrowd API in C to convert web pages and HTML documents to PDF. While it is perfectly fine to use C code in a C++ application, C++ programmers may prefer to integrate the API using modern C++.
You can download the complete C++ code with examples for quick integration into your project.
In this article, we will show how to convert a webpage or an HTML document to PDF in C using the Pdfcrowd API.
We will show the convert() function that provides the conversion functionality. We will demonstrate how to use it to create PDF from various input sources, such as a URL, a local HTML file, or an HTML string. By the end of this article, you should have a good understanding of how to integrate the Pdfcrowd API into your C programs for HTML to PDF conversion.
The API is cloud-based and accessible over HTTP. We will use libcurl to communicate with the API. libcurl is a widely used library available on all major platforms.
To quickly incorporate the Pdfcrowd API into your own code, you can download the complete C code with examples.
We have released a new version of our Save as PDF and Save as Image WordPress plugins.
New:
- Automatic retry of the conversion if the Pdfcrowd servers return error code 503.
Fixed:
- Replaced deprecated string interpolation.
We have released a new version of our API client libraries.
New:
- Automatic retry of the conversion if the Pdfcrowd servers return error code 503.
Fixed:
- PHP API client - replaced deprecated string interpolation.
We have released a new version of our API client libraries.
New:
- Added setCropAreaX, setCropAreaY, setCropAreaWidth, setCropAreaHeight and setRemoveBorders methods to ImageToImage and ImageToPdf API clients.
We have released a new version of our Save as PDF and Save as Image WordPress plugins.
New:
- Removed deprecated options "Auto Use Cookies" and "Use HTTP".
We expanded our suite of online tools. These are the new tools:
All the new tools, as well as the existing HTML to PDF and HTML to Image tools, are free to use. The Browser License removes our branding from the output documents.
Here is a complete list of our online tools. Feel free to contact us if you are missing any tool or feature.
We have released a new version of our API client libraries.
New:
- Added canvas setup options to the ImageToImage API client.
- Added page setup, watermark/background and output options to the ImageToPdf API client.
Fixed:
- Fixed an issue with image rotation other than 90/180/270 degrees in the ImageToPdf API client.