Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7768967
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T16:03:22+00:00 2026-06-01T16:03:22+00:00

I want to create a invoice as described in this post here . I

  • 0

I want to create a invoice as described in this post here.

I am able to do the edits here and get even the print. But I need some suggestion to store the same into Database. I am Good with MySQL, just a beginner in PHP, So can any one suggest me how to have multiple inserts. and storing the customer info in customer table, and order info in order table, and the relation between customer and Order in another. with reference to the above example.

Demo here.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T16:03:23+00:00Added an answer on June 1, 2026 at 4:03 pm

    They are 4 sections in the INVOICE system , Client Information , Invoice Information , Invoice Items and Items Total

    Invoice Information

    $mysqli = new mysqli ( $dbHost, $dbUser, $dbPass, $dbName ); // Replace with
                                                                 // relevant
                                                                 // information
    $result = $mysqli->query ( "SELECT * FROM invoiceInfo" );
    $invoice = $result->fetch_assoc ();
    
    
    
    <div id="page-wrap">
        <textarea id="header">INVOICE</textarea>
        <div id="identity">
    
            <textarea id="address">   
    <?php echo $invoice['address']?>
    </textarea>
    
            <div id="logo">
    
                <div id="logoctr">
                    <a href="javascript:;" id="change-logo" title="Change logo">Change
                        Logo</a> <a href="javascript:;" id="save-logo" title="Save changes">Save</a>
                    | <a href="javascript:;" id="delete-logo" title="Delete logo">Delete
                        Logo</a> <a href="javascript:;" id="cancel-logo"
                        title="Cancel changes">Cancel</a>
                </div>
    
                <div id="logohelp">
                    <input id="imageloc" type="text" size="50" value="" /><br /> (max
                    width: 540px, max height: 100px)
                </div>
                <img id="image" src="images/aviation/logo2.png" alt="logo" />
    
            </div>
    
        </div>
    

    Customer Information

    $result = $mysqli->query ( "SELECT *  FROM clientTable WHERE clientID = '{$invoice['clientID']}' " );
    $clientInfo = $result->fetch_assoc ();
    $totalPayment = 0;
    
    
    <div id="customer">
    
        <textarea id="customer-title"><?php echo $clientInfo['clientName']?>
    
    Address:  <?php echo $clientInfo['clientAddress'] ?>  </textarea>
    
        <table id="meta">
            <tr>
                <td class="meta-head">Invoice #</td>
                <td><textarea>000123</textarea></td>
            </tr>
            <tr>
    
                <td class="meta-head">Date</td>
                <td><textarea id="date"><?php echo date("Y-m-d g:i:s",time())?></textarea></td>
            </tr>
            <tr style="display: none">
                <td class="meta-head">Total Payment</td>
                <!-- <td><div class="due">-N-<?php echo $totalPayment ?></div></td>  -->
                <td><div>-N-<?php echo $totalPayment ?></div></td>
            </tr>
    
        </table>
    
    </div>
    

    Invoice Items

    <?php
        $result = $mysqli->query ( "SELECT *  FROM itemTable WHERE clientID = '{$invoice['clientID']}' " );
    
        while ( $item = $result->fetch_assoc () ) {
    
            ?>
        <tr class="item-row">
            <td class="item-name"><div class="delete-wpr">
                    <textarea><?php echo $item['name'] ?></textarea>
                    <a class="delete" href="javascript:;" title="Remove row">X</a>
                </div></td>
            <td class="description"><textarea>
        <?php echo $item['description']?>
        </textarea></td>
    
            <td><textarea class="cost">-N-<?php echo $item['unit'] ?></textarea></td>
            <td><textarea class="qty"><?php echo $item['quantity'] ?></textarea></td>
            <td><span class="price">-N-<?php echo $item['prize'] ?></span></td>
        </tr>
        <?php
        }
    ?>
    

    Item Total this would be done automatically

    I hope this helps

    Thanks
    🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to create conditional comments in XSLT. But when I use this: <!--
I want to create my own routing system with .htaccess , but I have
I want to create an invoice of every 2 week. An invoice can have
I need a way to create an invoice from multiple orders every month? In
I'm trying to write something like this: myStub.Stub(_ => _.Create(Arg<Invoice>.It.Anything)).Callback(i => { i.Id =
Sorry if this is already answered somewhere, but how do i create a foreign
I want create a excel with Apache POI in java and I must insert
i want create image animation , i have 50 images with png format now
I want create module which update list of usb devices automatically (not only mass
We want to create a widget platform for a particular website. I couldn't find

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.