• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Periods in URLs are removed

[eluser]Marcel Karras[/eluser]

have a look at the following request URL:
http://localhost/my_project/de/system/my_class/my_method/my_param/My parameter value./my_further_param/100/
The following PHP source lines are located in my_method:
echo '1: '.$this->uri->uri_string().'<br/>';
echo '2: '.$_SERVER['REQUEST_URI'];
The HTML output is as following:
1: http://localhost/my_project/de/system/my_class/my_method/my_param/My parameter value/my_further_param/100/
2: http://localhost/my_project/de/system/my_class/my_method/my_param/My%20parameter\%20value./my_further_param/100/
My allowed character config is:
$config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-';
My root system/.htaccess looks this:
RewriteEngine On
RewriteCond $1 !^(application|index\.php|index\.html|robots\.txt)
RewriteRule ^(.*)$ index.php/$1 [L]
Even if I set RewriteEngine to Off it has the same effect. Can someone help me on that?

- Marcel

Try the different settings of
$config['uri_protocol'] = ?;

[eluser]Marcel Karras[/eluser]
This is no option for me as I've been working with "AUTO" for the whole project and a change will effect the overall behavoir. Maybe the only chance for me is to use the Encryption Class and encode/decode the variables?

Quote:a change will effect the overall behavoir.
Your URLs still look the same, you just change CI's internal way on how to retrieve the URI segments. This shouldnt affect any of your code!

[eluser]Marcel Karras[/eluser]
If I use "QUERY_STRING" for instance not even the start page can be found. (404 errors on all pages) A change to "PATH_INFO" for instance brakes my "redirect('path/to/controller')" methods. Is there another way to circumvent this behavior?

How does path_info break your redirects?

[eluser]Marcel Karras[/eluser]
Sorry, it was "QUERY_STRING" not "PATH_INFO" but the latter doesn't affect the above described removing of periods.

Try updating the router and uri class, i just tested your url using 1.7.0 and the period stays in the uri_string.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.