Added Url encoding

by Jason Haley 14. September 2006 15:45

I added Url encoding to the Encoding page I created earlier today.  Now instead of http://www.jasonhaley.com/blog I can put http://%77%77%77%2e%6a%61%73%6f%6e%68%61%6c%65%79%2e%63%6f%6d/blog.

So if you put the two of them together you can take a link like this:

<a href="http://jasonhaley.com/blog">My Blog</a>

to a string like this:

<a href="&#104;&#116;&#116;&#112;&#58;&#47;&#47;%77%77%77%2e%6a%61%73%6f%6e%68%61%6c%65%79%2e%63%6f%6d&#47;&#98;&#108;&#111;&#103;">&#77;&#121;&#32;&#66;&#108;&#111;&#103;</a>

or for an image, something like this:

<img src="http://jasonhaley.com/images/home_header.jpg"/>

to a string like this:

<img src="&#104;&#116;&#116;&#112;&#58;&#47;&#47;%77%77%77%2e%6a%61%73%6f%6e%68%61%6c%65%79%2e%63%6f%6d&#47;&#105;&#109;&#97;&#103;&#101;&#115;&#47;&#104;&#111;&#109;&#101;&#95;&#104;&#101;&#97;&#100;&#101;&#114;&#46;&#106;&#112;&#103;"/>

If I get a chance tomorrow, I'll put something together to simplify a link and an image.

Comments (2) | Post RSSRSS comment feed |

Categories:
Tags:

Comments

Comments are closed