=== eBook Crafter – Convert Posts to PDF eBooks ===
Contributors: hypersonic, mehul0810, mmuhsin, usuual
Tags: ebook, pdf, print, publishing, blogging
Requires at least: 6.3
Tested up to: 7.0
Requires PHP: 8.1
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Turn the blog content you have already published into PDF eBooks you can sell, gate or give away.

== Description ==

eBook Crafter turns your existing posts, pages and custom post types into PDF eBooks, right from inside WordPress. Gather your finest content, edit it in the native block editor and export into PDF format.

Finished PDFs automatically appear in your Media Library, ready to sell as digital products or gate behind a membership plugin.

Check out the full video walkthrough of eBook Crafter:

https://www.youtube.com/watch?v=yH8TMbew1Rw

= From published posts to a product =

Every post you publish gets its traffic once and then goes into the archive. If you package that content as an eBook, the same content becomes something readers will be willing to pay for, sign up to gain access, or print and share offline. eBook Crafter handles the whole process where your content has already been created and saved.

= What will you make? =

* **Travel bloggers** sell travel guides built from posts they have already published.
* **Food bloggers** collect their readers' favorite recipes into a book worth paying for.
* **Marketers** create lead magnets that trade expert knowledge for email addresses.
* **Accountants** create invoice audits from invoices prepared over a year.
* **Educators** turn lessons from LifterLMS, TutorLMS or LearnDash into course packs and question banks. Pull in the relevant custom post types, edit in the block editor and export your PDF in minutes.
* **Photographers** present their best work in a print-ready format clients can buy.
* **Students and teachers** build yearbooks that capture a school year in pictures and text.
* **Anyone** can preserve their memories in a book to be printed and cherished someday.

= Three steps to a finished PDF =

1. **Gather.** Search your posts, pages and custom post types and pull them into your book as chapters.
2. **Craft.** Arrange cover pages and chapters and a table of contents will be auto-added. Next, fine-tune content for every page in the block editor interface.
3. **Publish.** Export a PDF and it will be automatically added to your Media Library. From there, you can then sell it with WooCommerce, attach it to an opt-in form or gate it behind a membership.

= Free features =

* Custom eBook post type
* Page, Chapter and Table of Contents blocks
* Local PDF generation with DOMPDF
* PDF version history in the media library

= Ready to take eBook creation to the next level? Meet Pro =

The DOMPDF engine that comes with the free version is great for getting started. [eBook Crafter Pro](https://ebookcrafter.com/) renders your book with the following benefits:
1. It includes Prince for high-fidelity rendering and print-grade typography. 
2. You get pre-made book templates, and the ability to add your own templates and custom fonts. 
3. Automatic page numbers are included in the table of contents
4. Build accessible PDFs through Prince – your eBook will work well with screen readers and meets common accessibility and archiving standards. Learn more: https://www.princexml.com/doc/prince-output/#pdf-accessibility
4. Get priority support and a direct say in feature requests for the future roadmap of eBook Crafter.

Pro features are provided entirely by the separate Pro plugin. This plugin contains no locked functionality.

== External services ==

This plugin connects to the jsDelivr CDN to fetch Twemoji emoji images during PDF generation.

* **What it is and what it is used for:** The bundled DOMPDF engine cannot render system emoji glyphs, so any emoji found in your book content are replaced with the open-source [Twemoji](https://github.com/jdecked/twemoji) PNG images, fetched from jsDelivr (`cdn.jsdelivr.net`) and embedded into the PDF.
* **What data is sent and when:** Only when you generate a PDF and only if the book content contains emoji. The request contains the Unicode codepoints of the emoji being rendered (as part of the image filename) and standard HTTP request metadata (such as your server's IP address). No personal data, content, or account information is transmitted. No requests are made while browsing or editing.
* **Service provider:** jsDelivr — [Terms of Service](https://www.jsdelivr.com/terms), [Privacy Policy](https://www.jsdelivr.com/terms/privacy-policy-jsdelivr-net). The Twemoji artwork is licensed under CC-BY 4.0.

== Source code ==

This plugin's JavaScript is built with [@wordpress/scripts](https://www.npmjs.com/package/@wordpress/scripts). The complete, human-readable source of every compiled file in `build/` is included in the plugin's `src/` directory, together with the build configuration (`package.json`, `webpack.config.js`, `postcss.config.js`).

To rebuild the compiled assets:

1. `npm install`
2. `npm run build`

PHP dependencies in `vendor/` are managed with Composer (`composer.json`); the bundled libraries (such as [Dompdf](https://github.com/dompdf/dompdf)) each carry their own license and repository information in their headers.

== Installation ==

1. Upload the plugin files to the `/wp-content/plugins/ebookcrafter` directory, or install the plugin through the WordPress plugins screen.
2. Activate the plugin through the 'Plugins' screen in WordPress.
3. Open **eBook Crafter** in the admin menu to create your first eBook.

== Frequently Asked Questions ==

= What WordPress and PHP versions are required? =

WordPress 6.3 or higher and PHP 8.1 or higher.

= Which content can I include in my eBook? =

Posts, pages and custom post types. If your lessons, recipes or portfolio items live in a custom post type, you can pull them into your book as chapters.

= Can I sell or gate the PDFs I create? =

Yes. Finished PDFs are saved to your Media Library, so you can sell them with WooCommerce or Easy Digital Downloads, attach them to an email opt-in or place them behind an exclusive membership using a membership plugin.

= Does the free version include the Pro PDF engine? =

No. The free version generates PDFs with DOMPDF on your server. Higher-fidelity Pro rendering is available in [Pro](https://ebookcrafter.com/).

= Does this plugin call external services? =

No account or API key is required, and PDFs are generated locally on your server. The only external request the plugin makes is fetching Twemoji emoji images from the jsDelivr CDN during PDF generation, and only when your book content contains emoji — see the "External services" section for details. Pro upgrades are purchased on ebookcrafter.com (external link only; no license SDK is bundled in this free plugin).

== Screenshots ==

1. Content tab — add content, format the pages
2. Build tab — version history with view, download, and delete actions

== Changelog ==

= 1.0.0 =
* WordPress.org free release based on the DOMPDF engine
* Soft Pro upsell for Pro features

== Upgrade Notice ==

= 1.0.0 =
Initial WordPress.org free release.