![]() |
Why can't I remove '/' after controller's name? like:www.domain.com/account/signup?fromID=8273 - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: Why can't I remove '/' after controller's name? like:www.domain.com/account/signup?fromID=8273 (/showthread.php?tid=25772) |
Why can't I remove '/' after controller's name? like:www.domain.com/account/signup?fromID=8273 - El Forum - 12-23-2009 [eluser]lovinglgz[/eluser] Once I updated to 1.7.2 I found I cant visit link like: http://www.domain.com/account/signup?fromID=8273 but the follow one is okay: http://www.domain.com/account/signup/?fromID=8273 seems it need a '/' after controller name. below is my config context about permitted url chars. $config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-\?\=&%'; Does anyone here can help me? Thanks in advance. Why can't I remove '/' after controller's name? like:www.domain.com/account/signup?fromID=8273 - El Forum - 12-24-2009 [eluser]BrianDHall[/eluser] What happens when you visit one vs the other? To make this sort of thin work depends upon how you are accessing the params, if query strings are enabled, uri protocol, and htaccess/server configuration for how it handles rewrites. Why can't I remove '/' after controller's name? like:www.domain.com/account/signup?fromID=8273 - El Forum - 12-25-2009 [eluser]Unknown[/eluser] I think it all depends on accessing params too. Why can't I remove '/' after controller's name? like:www.domain.com/account/signup?fromID=8273 - El Forum - 12-25-2009 [eluser]lovinglgz[/eluser] Thank you all. Actually I have 2 independent applications deployed on one server, and they share the same configuration, the only difference is one is based on 1.7.0 and the other is on 1.7.2. After a deep comparison I got some information that might result in such issue. In this file: system/library/Config.php 1.7.0: Code: return $this->slash_item('base_url').$this->slash_item('index_page').preg_replace("|^/*(.+?)/*$|", "\\1", $uri).$suffix; 1.7.2: Code: return $this->slash_item('base_url').$this->slash_item('index_page').trim($uri, '/').$suffix; What bring me down is when I rollback this line from 1.7.2 to 1.7.0, it still doesn't works, and say "404 Page Not Found. The page you requested was not found." I'm not sure whether it is the key point. Do you guys have ideas? Thanks again! |