Custom URL like www.companydirectory.com/mycompanyname/feedback in Codeigniter using htacess |
[eluser]Amitabh Roy[/eluser]
I posted this question at stackoverflow too, I am also posting it here, so that I can get this question to a more broader audience. I am developing a site on Codeigniter 2.0.2 . Its a site where companies/users can signup and create their own profile page, have their own custom url(like http://facebook.com/demouser), have their own feedback system, display their services. This said, I have been successful in display the profile page in the following format Code: http://mainwebsite.com/company/profile/samplecompany Now I have few questions, 1. I guess it is possible to create to have/get Code: http://mainwebsite.com/samplecompany 2. There will be few other pages for the given user/company such as feedback, contact us, services etc. So the implementation links that come to my mind is of the form ` Code: http://mainwebsite.com/samplecompany/feedback Code: http://mainwebsite.com/samplecompany/faq where samplecompany is the dynamic part Is it possible to create site links in the format?
[eluser]mdhb2[/eluser]
my code work with this htaccess : <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php/$1 [L] </IfModule> <IfModule !mod_rewrite.c> ErrorDocument 404 /index.php </IfModule> |
Welcome Guest, Not a member yet? Register Sign In |