HUB OF TUTORIALS
  • Business
  • Digital Marketing
  • Technology
    • HTML
    • CSS
    • jQuery
    • WordPress
    • Core PHP
    • Mysql
    • JAVA
    • Projects
    • Photography
  • Recipes
  • Others
  • Write for Us
HUB OF TUTORIALS
  • Business
  • Digital Marketing
  • Technology
    • HTML
    • CSS
    • jQuery
    • WordPress
    • Core PHP
    • Mysql
    • JAVA
    • Projects
    • Photography
  • Recipes
  • Others
  • Write for Us
  • Business
  • Digital Marketing
  • Technology
    • HTML
    • CSS
    • jQuery
    • WordPress
    • Core PHP
    • Mysql
    • JAVA
    • Projects
    • Photography
  • Recipes
  • Others
  • Write for Us
HUB OF TUTORIALS
  • Business
  • Digital Marketing
  • Technology
    • HTML
    • CSS
    • jQuery
    • WordPress
    • Core PHP
    • Mysql
    • JAVA
    • Projects
    • Photography
  • Recipes
  • Others
  • Write for Us
Core PHPHTMLMysql

How to Create an Invoicing system in PHP

In this article, we will explain How to Create an Invoicing system in PHP. the invoice will be inserted into the database.

Example:-

form.php

<?php
error_reporting( error_reporting() & ~E_NOTICE );

$item3=$_POST['item10'];
$quantity3=$_POST['qty10'];
$price3=$_POST['price10'];

$item3=$_POST['item9'];
$quantity3=$_POST['qty9'];
$price3=$_POST['price9'];

$vat=$_POST['vat'];
$total=$_POST['total'];
$grand=$_POST['grand'];
$amount10=$_POST['amount10'];
$amount9=$_POST['amount9'];
$insert="insert into invoice set 
item10='$item10',qty10='$quantity10',price10='$price10',amount10='$amount10',
item9='$item9',qty9='$quantity9',price9='$price9',amount9='$amount9',
total='$total', vat='$vat', grand='$grand',bal='$grand'";

$result=mysql_query($insert);
header("location:index.php");
}
?>

db.php

<?php
mysql_connect('localhost','root','');
mysql_select_db('testbill');

?>

index.php

<html>
<head>
<title>Invoicing System</title>
</head>
<body>
<form method="POST">
<div class="row1">
	
		<h4>Party Name</h4><input type="text" name="party_name" >
		
	</div>
							<thead>
                                    <tr>
									<td>Item </td>
		<td>Quantity</td>
		<td>Price</td>
		<td>Amount </td> 
<td></td>		
                                       
                                    </tr>
                                </thead>
                                <tbody>
        
		<tr>
		<td>
		
		
		<td><input type="text" style="width:45px;" name="item8"/></td>
		
		<td><input type="text" name="qty10" style="width:45px;" value="<?php echo $quantity10 ;?>"/></td>
		<td><input type="text" name="price10" style="width:45px;" value="<?php echo $price10 ;?>"/></td>
		<td><input type="text" name="amount10" style="width:45px;" value="<?php echo $amount10 ;?>"/> </td>
		<td></td>
		</tr>
		    <tr>
		<td> 
		<td><input type="text" style="width:45px;" name="item8"/></td>
		
		<td><input type="text" name="qty9" style="width:45px;" value="<?php echo $quantity9 ;?>"/></td>
		<td><input type="text" name="price9" style="width:45px;" value="<?php echo $price9 ;?>"/></td>
		<td><input type="text" name="amount9" style="width:45px;" value="<?php echo $amount9 ;?>"/> </td>
		<td></td>
		</tr>
	
		<tr>
		<td colspan="3" align="right">Total</td>
		<td><input type="text" name="total" style="width:45px;" value="<?php echo $total;?>"/></td>
		<td></td>
		</tr>
				
		<tr>
	<td colspan="3" align="right" >Vat </td>
		<td>
		<select name="vat"> 
		<option value=""></option>
		<option value="10" selected="selected">10</option></select></td>
		<td></td>
		</tr>
		
		<tr>
		<td colspan="3" align="right" >Grand Total</td>
		<td><input type="text" name="grand" style="width:45px;" value="<?php echo $grand;?>"/></td>
		<td></td>
		</tr>
		<tr>
		<td><input type="submit" name="cal" value="cal"/></td>
		<td><input type="submit" name="submit" value="save"/></td>
		<td></td><td></td><td></td>
		</tr>
		            
                                 </tbody>
								 </form>
</body>
</html>
bill generator business software free billing software invoice invoice bill invoice format invoice template invoicing software online accounting software
How to Create Chaining in jQueryPrevHow to Create Chaining in jQueryMarch 16, 2020
How to Create User Registration and login using Stored Procedure in PHPMarch 16, 2020How to Create User Registration and login using Stored Procedure in PHPNext
Search
Recent Posts
  • How Students Can Increase Their Academic Productivity With Paraphrase Tool?
  • 7 Educational Approaches for Diverse Learners
  • 5 Best Online Payment Gateways in India
  • How to Start and Earn from Making WooCommerce Plugins
  • Step By Step Guide to Becoming a Certified Salesforce Developer
Categories
  • Business
  • Core PHP
  • CSS
  • Digital Marketing
  • HTML
  • JAVA
  • Jobs
  • jQuery
  • Mysql
  • News
  • Others
  • Photography
  • Projects
  • Recipes
  • WordPress

  • How to Create List in HTML
  • How to use Iframe in HTML
  • How to Create a Table in HTML and CSS
  • How to Add New HTML Content using jQuery
  • CSS Property of List tag in HTML
  • How to use CSS for Table in HTML
  • How to Make Basmati Rice Recipe
  • How to Make Indian Kheer Recipe
  • How to Make Spicy Aloo Tikki
  • How to Make Aloo Matar Samosa
  • How to Make Cheese Potato Sandwich
  • How to Make Aloo Palak Methi
  • Company Visitors Management System
  • Complaint Management System using PHP
  • Directory Management System
  • Employee Record Management System
  • Hospital Management System using PHP
  • Vehicle Parking Management System

Copyright © 2022 Hub of Tutorials. All Rights Reserved. Designed by AS Webworks