Raya Deleva’s Web

/ Web development

Plus sign and URL or "URL syntax for special characters"

While trying yesterday to add two plus signs (++)  in  <a href=""> tag, I realized that something is wrong and actually I cannot just write the second param with value EC++BDSE.

Example: ...jobs.php?loc=Sofia&jobid=EC++DSE

These two ++ signs in the "jobid" param will be skipped, when you try to pass them. So I found the right way to code that kind of special signs in URL. Below in the table you will see how you have to replace special characters.

The correct coding of the above URL is:
...jobs.php?loc=Sofia&jobid=EC%2B%2BDSE

 

Character URL Syntax Description
%20 Space
' %27 Foot Sign
" %22 Quote
# %23 Number sign
% %25 Percent sign
& %26 Ampersand
+ %2B Plus sign
/ %2F Solidus (slash)
: %3A Colon
; %3B Semicolon
< %3C Less than
> %3E Greater than
? %3F Question mark

Some of the characters are replaced automatically by browsers, but some of them like the plus sign are not, so it is better to replace them all with their URL syntax. 

category: Web development, posted date: 14.04.2007, Comment

Add your comment here.

Your name*

Your email

Your comments, suggestions, compliments or maybe other?*


What is this blog about? - A blog about sharing wisdoms mostly connected with web development. I truly hope that you will find something useful here. Cheers, Raya.
» About
» Playlist (Social music experiment)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

 Subscribe

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
CSS Beauty A List Apart W3schools The best forum for development in Bulgarian CSS Zen Garden Photo Cult PEAR - PHP Extension and Application Repository Rapid development framework for PHP
My lovely friend Bobbyta Awesome! - Mootools Smashing Magazine