0

I need to add a semicolon (;) to the Codeigniter permitted URL chars pattern, here is the code:

$config['permitted_uri_chars'] = 'a-z 0-9~%.:_-';

I need to add the semicolon (I need this because some semicolons are passed with the URL), but I don't know how to add it to the pattern.

Thanks in advance!

2 Answers2

0

You many not use semicolon's in the URL except for it's intended purpose.

Can a URL contain a semi-colon?

Does this not work?

$config['permitted_uri_chars'] = 'a-z 0-9~%.:_-;';
Community
  • 1
  • 1
Kirk Backus
  • 4,776
  • 4
  • 32
  • 52
0

You can insert the ';' in that config string.

Instead of a semicolon in the url, you could insert it's url encoded version '%3b'

So:

http://www.example.com/some%3bthing

%3b is a semicolon, such as %20 is a white space.

More info: http://webdesign.about.com/library/bl_url_encoding_table.htm

Luc
  • 331
  • 3
  • 8