Today is . Page created 03/24/07

Subtraction Problems Subtraction Worksheet Generator Generator

This window will prepare a page of subtraction problems (up to 30) which can be printed for a worksheet. The answers will be listed in the box on the right - you might want to cut and paste them elsewhere.

Enter the length of the minuend: (1-5 digits)
Enter the length of the subtrahend (1-5 digits)
Enter the number of problems (1-30)



Generates a subtraction worksheet of up to 30 problems in an easy to read, printable format. The script can be readily changed to accomodate addition and multiplication. The worksheet is prepared in a separate window with graphic numerals for ease of reading.

We have tested the code in IE7.0, Firefox2.0.0.2, Opera9.10, Netscape8.1.2 and AOL Explorer1.5. This script worked well in all platforms with one (1) variation observed in Opera9.10.

Depending on your knowledge of HTML and javascripts, this is an easy two (2) part copy and paste code (no reconfigurations) that goes in both the <HEAD> and <BODY> section (wherever you want it to appear) of your document. From the script site you will need to download a zip file with all the graphics (59)* plus the code which is in the form of a complete HTML document. Just study the complete HTML code and weed out the parts that are not part of the script and what you do not need.

*     When you download the zip file from the script site and prior to uploading the fifty-nine (59) graphics there are two (2) things you must do or the generator will not show any images when you click "Prepare Worksheet" and you will wonder why.

  1. Change the case of the name and extension on every image (all 59 of them). The images and file extension are capital (CAPS) and the way the script is configured it requires lowercase. See below:
    Default ----- Wrong way:     C1.GIF, DUSP.GIF
    Reconfigured ----- Right way:     c1.gif, dusp.gif


  2. Make a new "Sub-Directory", named "digis" (no quotes lowercase) and upload all the reconfigured images into that directory. Reason being is that the script is configured to call all the images from that named directory and it is extremely complicated to attempt to explain howto change the entire code so a work-a-round is to just make a new sub-directory to avoid any problems.

For Your Information For your Information:     ~ Domain names are "not case sensitive", but directories and filenames are! (Including file extensions) gif is not the same as GIF, DIGIS is not the same as digis and DUSP is not the same as dusp.

Once you have done the above reconfigurations and uploaded all the graphics into your newly created directory, paste the <HEAD> and <BODY> section (anywhere you want it to appear and you are done.

Warning Logo     Note Of Importance:     On the page you are going to have this effect on or any page that will link to the page with this effect on it, be sure of one thing within either the linking URL or the URL this effect is on. Be sure you "Do Not" have the backslash-forward slash / (which ever you call it) at the end of the linking URL. If you do, the effect "Will Not Work! (none of the graphics will appear and all you will see is the infamous little red X and wonder why. If this sounds confusing, see the below example:

  • Right Way:     https://www.angelfire.com/ny5/consigliere/subtractionworksheetgenerator.html

  • Wrong Way:    'https://www.angelfire.com/ny5/consigliere/subtractionworksheetgenerator.html/

Select the links above to see what we are explaining about the Right and Wrong URL address.

Add-On Not Included In Script Little Extra Not Included In The Script:     The last this we shall cover is to make the <HEAD> section of the script into an external.js file and called from an external location. Reason you may want to do this is quite simple. The <HEAD> section is large and takes up alot of space. If you need a little refresher on howto, see below.

The <HEAD> section of code starts and ends with opening and closing JavaScript tags, See below:

  • Opens With:
    <script language="javascript">

    <HEAD> Section of code goes here

  • Closes With:
    </script>
  1. Remove the opening and closing JavaScript tags.
  2. Copy/cut and paste everything in-between into a notepad and save it as subtractionGenerator.js*
  3. The newly created (Saved As) file will look something like this   subtractionGenerator.js
  4. Upload the newly created subtractionGenerator.js into your directory
  5. Paste the below snipplet of code into the <HEAD> section of your document to call subtractionGenerator.js
    <script type="text/javascript" src="subtractionGenerator.js"> </script>
  6. If you have uploaded the subtractionGenerator.js into a different directory, you will have to change the path of the above to reflect the location.
  7. If changing the path is a little confusing, grab the below link and it is explained in detail.
    Upload To Different Directory ]
* We named our external.js file subtractionGenerator.js. This is just so we know what it is to at any given moment. You can name it anything you want. This is entirely up to you on this.

If you would like to see an example of this effect with the use of an external.js file in the <HEAD> section, grab the below link and you are there.
Subtraction Worksheet Generator With External.JS File ]

On A Final Note     If you would like to change the subtraction sign ( - ) on the printable worksheet to that of either the plus ( + ) sign for addition or the ( x ) for multiplication, see the below on where and howto. These reconfigurations are made within the <HEAD> section close to the beginning of the script.

Default - With Minus ( - ) Sign

// Graphics routines........
gnum="<img src=\"digis/c";
gdf="<img src=\"digis/d";
gduf="<img src=\"digis/du";
ge=".gif\">"
gop="<img src=\"digis/op2.gif\">";
gsp="<img src=\"digis/dsp.gif\">"; // space
gusp="<img src=\"digis/dusp.gif\">"; //underlined space
gcsp="<img src=\"digis/spsp.gif\">"; //spacer below counter
show=" ";
check=" ";

Reconfigured - With Plus ( + ) Sign

// Graphics routines........
gnum="<img src=\"digis/c";
gdf="<img src=\"digis/d";
gduf="<img src=\"digis/du";
ge=".gif\">"
gop="<img src=\"digis/op1.gif\">";
gsp="<img src=\"digis/dsp.gif\">"; // space
gusp="<img src=\"digis/dusp.gif\">"; //underlined space
gcsp="<img src=\"digis/spsp.gif\">"; //spacer below counter            
show=" ";
check=" ";

Reconfigured - With Multiplication ( x ) Sign

// Graphics routines........
gnum="<img src=\"digis/c";
gdf="<img src=\"digis/d";
gduf="<img src=\"digis/du";
ge=".gif\">"
gop="<img src=\"digis/op3.gif\">";
gsp="<img src=\"digis/dsp.gif\">"; // space
gusp="<img src=\"digis/dusp.gif\">"; //underlined space
gcsp="<img src=\"digis/spsp.gif\">"; //spacer below counter          
show=" ";
check=" ";

  • Question: What is op2.gif, op3.gif and op1.gif?
  • Answer: They are the three images associated with the mathematical signs
  • op2.gif       <img src="digis/op2.gif\">
  • op3.gif       <img src="digis/op3.gif\">
  • op1.gif       <img src="digis/op1.gif\">

For Your Information For your Information:     The above reconfigurations will just change the mathematical sign of the printable page that appears when you click "Prepare Worksheet". It does not reconfigure the answers from the default subtraction to that of the changed graphic. These answers must be calculated manually. The script will not make the new calculations. This can't be changed unless you rewrite the entire script. If this is a little unclear, grab the below link to clarify it further.
Clarification On Above ]

We hope our tutorial was easy to follow and we covered everything in detail. If you would like to add this effect into your pages, grab the respective below link and you are there. If you have any problems with this or anything else, feel free to consult our FAQ ] and if you can't find the answer there, contact us ].
Get Code Here ]   [ Rate This Page ]  

Talk Live To A Support Technician

Search Our Site By Individual letter

A ]  [ B ]  [ C ]  [ D ]  [ E ]  [ F ]  [ G ]  [ H ]  [ I ]  [ J-K ]  [ L ] 
M ]  [ N-O ]  [ P-Q ]  [ R ]  [ S ]  [ T ]  [ U-V ]  [ W ]  [ X-Y-Z ] 

Little Tips Directory

Page 1  ] [ Page 2 ] [ Page 3 ] [ Page 4 ] [ Page 5  ] [ Page 6  ] [ Page 7  ]

Index Page 1 ] [ Index Page 2 ] [ Index Page 3 ] [ Index Page 4 ] [ Index Page 5 ]
Index Page 6 ] [ Index Page 7 ] [ Index Page 8 ] [ Index Page 9 ] [ Index Page 10 ]
Index Page 11 ] [ Index Page 12 ] [ Index Page 13 ] [ Form Index ]
2001 ] [ 2002 ] [ 2003 ] [ 2004 ] [ 2005 ] [ 2006 ] [ 2007 ]

News Letter Archives ] [ Navigation Page ] [ Archives Of Published Material ]
Link To Us ] [ Alphabet Index ] [ Feedback ] [ On Line Support ] [ FAQ ]
Webmaster Utilities ] [ Casino ] [ Banner Exchange ] [  Advanced Site Search ]

If you are part of the ever growing number of webmasters who enjoy sharing your knowledge with others on web design, join The Consigliere Ltd. web ring to broaden your scope of exposure.
Join Today

This Site Was Built And Is Maintained Exclusively by
The Webmaster @ Consigliere Ltd.

Copyright © Consigliere Ltd., All Rights Reserved. 2001-