So, how to use this awesome stuff on your website? Easy!

1. Download ySpeed.js

Simply save the script and upload it on your server.

2. Include the script and create object

Of course you need to first include the script on the page using the path you have uploaded it to. Then create an instance of the ySpeed object:

y = new ySpeed();

3. Get Your Text and Convert It

The following might be called on the body "onload" event or by a button click like in our example.


// "myTextContainer" is the ID of the div whose text you want to convert
var textToConvert = document.getElementById('myTextContainer'); 
// here below you are assigning the converted content back to the container
document.getElementById('myTextContainer').innerHTML = y.patseText(textToConvert);