PHP Script to Make an Invoice - Save to PDF, DOCX, HTML formats

PDF/DOCX/HTML Invoice Generation
This PHP source code allows you to generate PDF/DOCX/HTML invoices. You can print generated invoice out straight from the system or email them to the customer from the system. You also have control over the PDF/DOCX/HTML layout. Adjust the provided PDF template to suit your needs using the WYSIWYG editor. There is also a HTML editor available for more advanced PDF layout changes.

Create PDF Invoices by PHP source code
Your customers need PDF invoices – sometimes it's required by law, sometimes it's easier for them to upload PDFs into their booking system.

Our PDF Invoice plugin helps you and your customers to solve this problem automatically. With a few clicks your users will automatically get invoice PDFs attached to their order emails, thank you page & order details.

Furthermore you can modify the layout as you want: Add header, add address blocks, add custom invoice texts, images, logo, HTML or whatever you want. Display taxes in the correct way including tax rate and use our unique preview function to see the generated invoice template.

Don't Waste Time to write an PDF Invoice Maker by yourself.
Using our invoice maker you can make PDF/DOCX/HTML invoices in seconds from over more invoices templates designed by professionals for your business. Unlike Word Template based invoices where you have to type everything out by hand every time you need to make an invoice, our invoice maker app saves all of your information for you to import with just one click. When you create a new invoice, the online invoice maker automatically imports basic information such as your business name, address and phone number while you can add saved items to save even more time. Better yet, if you make a mistake on an invoice or a customer changes their mind about what they need you can go back and edit your existing invoice instead of using the online invoice maker to make an entirely new one. Take a look at the features of the invoice maker’s templates below.

Basic Invoice Template
Includes necessary information for billing such as invoice number, business and customer addresses, item descriptions and taxes for fast and easy invoicing.

Advanced Invoice Template
Add as many details as you wish including item quantities, purchase order numbers and invoice due date-all with unlimited character space.

More Invoice Template
All of the professionally designed invoice templates are free to use. Simply choose your favorite template, add your information and you’ll have one finished invoice to print or email.

PDF Invoice Templates
Download and save all of your finished invoices in PDF form for easy emailing and printing. Store all of your PDFs right in your account for easy record keeping.

Excite Your Customers
Invoice Home works with professional graphic designers and consults with business/tax professionals to give you the best looking and most efficient invoices out there. You can even set your own personal business logo to our invoice maker to promote your brand and leave your customers impressed.

Multiple Ways to Customize
Besides amazing design, you can customize our invoice templates to suit your global customers as our invoice maker supports multiple currencies and languages. If you have an online business and need to ship goods worldwide, you can change the currency on your invoice with one click.

Requirements:

  • PHP
  • CSS3
  • HTML5
  • IE7+, Firefox 3+, Chrome, Safari, Opera

Sample PHP source code:

[?php
/*
 * INVOICR : THE PHP INVOICE GENERATOR (HTML, DOCX, PDF)
 * 
 * ! YOU CAN DELETE THE ENTIRE EXAMPLE FOLDER IF YOU DON'T NEED IT... !
 */

/* [STEP 1 - CREATE NEW INVOICR OBJECT] */
require dirname(__DIR__) . DIRECTORY_SEPARATOR . "invoicr.php";
$invoice = new Invoicr();

/* [STEP 2 - FEED ALL THE INFORMATION] */
// 2A - COMPANY INFORMATION
// OR YOU CAN PERMANENTLY CODE THIS INTO THE LIBRARY ITSELF
$invoice-]set("company", [
	"https://veryutils.com/image/catalog/logo.png",
	__DIR__ . DIRECTORY_SEPARATOR . "logo.png", 
	"VeryUtils", 
	"Street Address, City, State, Zip",
	"Phone: xxx-xxx-xxx | Fax: xxx-xxx-xxx",
	"https://veryutils.com",
	"support@veryutils.com"
]);

// 2B - INVOICE INFO
$invoice-]set("invoice", [
	["Invoice #", "CB-123-456"],
	["DOP", "2011-11-11"],
	["P.O. #", "CB-789-123"],
	["Due Date", "2011-12-12"]
]);

// 2C - BILL TO
$invoice-]set("billto", [
	"Customer Name",
	"Street Address", 
	"City, State, Zip"
]);

// 2D - SHIP TO
$invoice-]set("shipto", [
	"Customer Name",
	"Street Address", 
	"City, State, Zip"
]);

// 2E - ITEMS
// YOU CAN JUST DUMP THE ENTIRE ARRAY IN USING SET, BUT HERE IS HOW TO ADD ONE AT A TIME... 
$items = [
	["Rubber Hose", "5m long rubber hose", 3, "$5.50", "$16.50"],
	["Rubber Duck", "Good bathtub companion", 8, "$4.20", "$33.60"],
	["Rubber Band", "", 10, "$0.10", "$1.00"],
	["Rubber Stamp", "", 3, "$12.30", "$36.90"],
	["Rubber Shoe", "For slipping, not for running", 1, "$20.00", "$20.00"]
];
foreach ($items as $i) { $invoice-]add("items", $i); }

// 2F - TOTALS
$invoice-]set("totals", [
	["SUB-TOTAL", "$108.00"],
	["DISCOUNT 10%", "-$10.80"],
	["GRAND TOTAL", "$97.20"]
]);

// 2G - NOTES, IF ANY
$invoice-]set("notes", [
	"Cheques should be made payable to VeryUtils",
	"Get a 10% off with the next purchase with discount code Test1234!"
]);


/* [STEP 3 - OUTPUT] */
// 3A - CHOOSE TEMPLATE, DEFAULTS TO SIMPLE IF NOT SPECIFIED
$invoice-]template("apple");

/*********************************************************************/
// 3B - OUTPUT IN HTML
// DEFAULT DISPLAY IN BROWSER | 1 DISPLAY IN BROWSER | 2 FORCE DOWNLOAD | 3 SAVE ON SERVER
// $invoice-]outputHTML();
// $invoice-]outputHTML(1);
// $invoice-]outputHTML(2, "invoice.html");
$invoice-]outputHTML(3, __DIR__ . DIRECTORY_SEPARATOR . "_invoice.html");
/*********************************************************************/
// 3C - PDF OUTPUT
// DEFAULT DISPLAY IN BROWSER | 1 DISPLAY IN BROWSER | 2 FORCE DOWNLOAD | 3 SAVE ON SERVER
// $invoice-]outputPDF();
// $invoice-]outputPDF(1);
// $invoice-]outputPDF(2, "invoice.pdf");
$invoice-]outputPDF(3, __DIR__ . DIRECTORY_SEPARATOR . "_invoice.pdf");
/*********************************************************************/
// 3D - DOCX OUTPUT
// DEFAULT FORCE DOWNLOAD| 1 FORCE DOWNLOAD | 2 SAVE ON SERVER
// $invoice-]outputDOCX();
// $invoice-]outputDOCX(1, "invoice.docx");
$invoice-]outputDOCX(2, __DIR__ . DIRECTORY_SEPARATOR . "_invoice.docx");
/*********************************************************************/
?]

Write a review

Note: HTML is not translated!
    Bad           Good
Captcha

PHP Script for PDF, DOCX, HTML Invoice Maker/Creator

  • Brand: VeryDOC
  • Product Code: MOD190228164943
  • Availability: In Stock
  • Viewed: 19369
  • Sold By: VeryDOC
  • Seller Rating:
  • Seller Reviews: (0)
  • $49.95

  • Ex Tax: $49.95

Available Options


Related Products

DOC to Any Converter Command Line

DOC to Any Converter Command Line

DOC to Any Converter Command Line can be used to batch convert DOC, DOCX, DOCM, RTF, TXT, PPT, PPT..

$79.00 Ex Tax: $79.00

PDF Virtual Printer SDK Based on Postscript Printer Driver for Developer Royalty Free

PDF Virtual Printer SDK Based on Postscript Printer Driver for Developer Royalty Free

PDF Virtual Printer SDK Based on Postscript Printer Driver for Windows Developers Royalty Free PDF ..

$1,500.00 Ex Tax: $1,500.00

PDF to HTML5 Flipbook Converter Command Line

PDF to HTML5 Flipbook Converter Command Line

PDF to HTML5 Flipbook Converter Command Line is a Windows software. PDF to HTML5 Flipbook Converter ..

$59.95 Ex Tax: $59.95

PDF Toolkit Command Line Tools & Utilities

PDF Toolkit Command Line Tools & Utilities

PDF Toolkit Command Line Tools & UtilitiesPDF Toolkit Command Line gives you a wide range of profess..

$199.00 Ex Tax: $199.00

Save
25%

PHP Ajax Mailer With Multiple Attachments

PHP Ajax Mailer With Multiple Attachments

PHP Ajax Mailer With Multiple Attachments Hey there, hope you are doing well, if you are looking ..

$14.95 $19.95 Ex Tax: $14.95

VeryPDF OCR to Any Converter SDK (OCR SDK)

VeryPDF OCR to Any Converter SDK (OCR SDK)

VeryPDF OCR to Any Converter SDK can be used to convert scanned PDF, TIFF and Image files (JPEG, J..

$595.00 Ex Tax: $595.00

Save
50%

PHP Batch Email Sender

PHP Batch Email Sender

PHP Batch Email Sender is a PHP script to batch send the emails from Command Line or on schedule. Ba..

$49.95 $99.95 Ex Tax: $49.95

DocVoicer (Text-To-Speech) Software

DocVoicer (Text-To-Speech) Software

DocVoicer is a Text-To-Speech (TTS) software to read Text, PDF, MS Office, OpenOffice, Web Page an..

$39.95 Ex Tax: $39.95

BizSoft Invoice for small businesses

BizSoft Invoice for small businesses

BizSoft Invoice -- Online invoicing software for small businesses BizSoft Invoice is an online invo..

$49.95 Ex Tax: $49.95

Email RSS Feeds as PDF Newspaper

Email RSS Feeds as PDF Newspaper

Convert RSS Feeds to PDF Newspaper with Email Subscription RSS Feeds To PDF Maker is a PHP Script..

$299.00 Ex Tax: $299.00

PDF Highlighter Command Line

PDF Highlighter Command Line

PDF Highlighter Command Line PDF Highlighter Command Line is a command line application which can b..

$299.00 Ex Tax: $299.00

PDF to SVG Converter Command Line

PDF to SVG Converter Command Line

PDF to SVG Converter Command Line VeryUtils PDF2SVG is a multi-platform command-line application fo..

$295.00 Ex Tax: $295.00

XPS to PDF Converter Command Line

XPS to PDF Converter Command Line

XPS to PDF Converter Command Line does convert from XPS and OXPS files to PDF and Image files. Bo..

$79.00 Ex Tax: $79.00

Save
38%

JavaScript PDF Creator Library

JavaScript PDF Creator Library

JavaScript PDF Creator is a client library to generate PDFs in pure JavaScript. JavaScript PDF Cre..

$49.95 $79.95 Ex Tax: $49.95

Tags: docx invoice, html invoice, invoice maker, make invoice, make receipt, pdf invoice, php script