Cross Stitch Calculator
3. Javascript
Join the Discussion
More of this Feature
With our calculator inserted into the web page and looking the way we want all that remains is to copy the below Javascript code ans save it as stitch.js.
We attach this into the head of our page with the following code
<script type="text/javascript" src="stitch.js">
</script>
</script>
The actual calculations that this calculator performs are actually quite simple and so as with most Javascript calculators the majority of the code that is needed is for validating the values entered and making sure that they are in the right format.

