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 7607137
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T00:35:10+00:00 2026-05-31T00:35:10+00:00

I have an order receipt page auto generated by our system. I need to

  • 0

I have an order receipt page auto generated by our system. I need to add barcodes for each order number. I have the basis set up, but I am running into two problems.

1) The barcode is printing using the first order number each time. I need each order to print its own bar code right below. (orders are in sequential order, but sometimes can skip order numbers)

2) The jquery is running multiple times as the system is going to place the code after each order. I cannot remove the jquery after each order, so how can I make it only run once after all orders have been loaded to the single document.

Below is a small piece of the entire order. I have used table width and font size to declare the areas I need as the system did not give them ids or classes. The only nice thing is font size 3 is never used anywhere else and same as table width 180, so I believe I will be fine in both cases. Thank you for your help.

jQuery code

$("table[width='180']").after("<img id='bar_code'");

$('img#bar_code').attr('src', 'http://www.barcodesinc.com/generator/image.php?code=' + $("font[size='3']").children().html() + '&style=197&type=C128B&width=150&height=50&xres=1&font=3');

HTML code

    <table width=180 border=0 cellpadding=0 cellspacing=0>
    <tr> 
        <td width=90 align=left colspan="2"><b><font style="font-size:18px;font-weight:bold;">PACKING SLIP</font></b></td>
    </tr>
    <tr> 
        <td width=90 align=left><b>Date:</b></td>
        <td width=90><b>Order#:</b></td>
    </tr>
    <tr> 
        <td width=75 align=left> 05/17/2011 </td>
        <td><font size=3><b>10122</b></font></td>
    </tr>
</table>
<br><br><br>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script>
<script>
$("table[width='180']").after("<img id='bar_code'");

$('img#bar_code').attr('src', 'http://www.barcodesinc.com/generator/image.php?code=' + $("font[size='3']").children().html() + '&style=197&type=C128B&width=150&height=50&xres=1&font=3');
</script>

    <table width=180 border=0 cellpadding=0 cellspacing=0>
    <tr> 
        <td width=90 align=left colspan="2"><b><font style="font-size:18px;font-weight:bold;">PACKING SLIP</font></b></td>
    </tr>
    <tr> 
        <td width=90 align=left><b>Date:</b></td>
        <td width=90><b>Order#:</b></td>
    </tr>
    <tr> 
        <td width=75 align=left> 05/17/2011 </td>
        <td><font size=3><b>10123</b></font></td>
    </tr>
</table>
<br><br><br>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script>
<script>
$("table[width='180']").after("<img id='bar_code'");

$('img#bar_code').attr('src', 'http://www.barcodesinc.com/generator/image.php?code=' + $("font[size='3']").children().html() + '&style=197&type=C128B&width=150&height=50&xres=1&font=3');
</script>


    <table width=180 border=0 cellpadding=0 cellspacing=0>
    <tr> 
        <td width=90 align=left colspan="2"><b><font style="font-size:18px;font-weight:bold;">PACKING SLIP</font></b></td>
    </tr>
    <tr> 
        <td width=90 align=left><b>Date:</b></td>
        <td width=90><b>Order#:</b></td>
    </tr>
    <tr> 
        <td width=75 align=left> 05/17/2011 </td>
        <td><font size=3><b>10124</b></font></td>
    </tr>
</table>
<br><br><br>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script>
<script>
$("table[width='180']").after("<img id='bar_code'");

$('img#bar_code').attr('src', 'http://www.barcodesinc.com/generator/image.php?code=' + $("font[size='3']").children().html() + '&style=197&type=C128B&width=150&height=50&xres=1&font=3');
</script>


    <table width=180 border=0 cellpadding=0 cellspacing=0>
    <tr> 
        <td width=90 align=left colspan="2"><b><font style="font-size:18px;font-weight:bold;">PACKING SLIP</font></b></td>
    </tr>
    <tr> 
        <td width=90 align=left><b>Date:</b></td>
        <td width=90><b>Order#:</b></td>
    </tr>
    <tr> 
        <td width=75 align=left> 05/17/2011 </td>
        <td><font size=3><b>10127</b></font></td>
    </tr>
</table>
<br><br><br>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js"></script>
<script>
$("table[width='180']").after("<img id='bar_code'");

$('img#bar_code').attr('src', 'http://www.barcodesinc.com/generator/image.php?code=' + $("font[size='3']").children().html() + '&style=197&type=C128B&width=150&height=50&xres=1&font=3');
</script>
  • 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-05-31T00:35:12+00:00Added an answer on May 31, 2026 at 12:35 am

    I know it’s a bit late, but I was browsing through unanswered questions and noticed you forgot to close your image tags. In your script, by changing this:

    $("table[width='180']").after("<img id='bar_code'");
    

    to this:

    $("table[width='180']").after("<img id='bar_code'>");
    

    The script works perfectly…

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

Sidebar

Related Questions

Basically in order to have a profile Block u need - let's say profile
I have an Order object to represent a Prospective Order/Receipt. This is an entity.
I have an MSMQ-based system with three layers that communicate with each other. For
Does anybody knows how to get the ORDER number inserted in page attributes? I
I have an order entry system in Silverlight. I have two tables - Orders
I have order object and I need to get all shipped package tracking numbers.
Lets say I have data in two tables. In one I have Order ID
I have an order form with about 30 text fields that contain numerical values.
I have a order list and I want to generate and rank the product
Let's say I have an Order table which has a FirstSalesPersonId field and a

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.