Zend Certified Engineer

phpguru.org

Quality PHP and Javascript code
Download RGraph: HTML5 canvas graph library... Home ~ Downloads ~ FAQs ~ Licensing
RSS Feed RSS Feed
Follow me on Twitter Follow me on Twitter

Add to Google...

HTML5 & CSS3

Articles

Javascript

PHP5

PHP4






Licensing

All the code here is covered by the PHPGuru license. A short summary is that for any sort of commercial use there is a small one-off licensing fee to pay, and for charity and educational use there is a reduced license fee.

You can read more about licensing here (where there's also a link to Google Checkout).

Update
Looking around at what's available, I've found this. It's much better.

CanvasText: How to get text on your canvas (HTML5)

A Javascript library that allows you to write simple text to your canvas.

You need to upgrade your browser! Internet Explorer 7 or lower does not support the canvas tag.

You need to upgrade your browser! Internet Explorer 7 or lower does not support the canvas tag.

The source that produces this text is:

<script type="text/javascript" src="CanvasText.js"></script>

This pulls in the CanvasText library. And this...

<script type="text/javascript">
<!--
    CanvasText(document.getElementById("myCanvas"), // The canvas object
               'ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789', // The text to write
               10, // The X position (the bottom left corner of the text)
               20, // The Y position (the bottom left corner of the text)
               10); // The text height in pixels
// -->
</script>

...simply draws the alphabet. Wonderful eh?

Note: This library is quite large at around 12k, so you may want to gzip it, for example mod_gzip should do it automatically for you. If you're not using Apache, you're on your own... :-) The gzipped version comes out at under 2k - quite a reduction.