views:

52

answers:

4

Hi,

Actully i am a java developer and new to PHP, I am using Code Ignitor as a frame work for my project.Setup site on my local machine. And accessing site using following URL.

http://localhost/businesscaliber/index.php/home

Where home is HomeController. here i want to context as

http://localhost/businesscaliber rather than above URL.

A: 

You need to use .htaccess and mod_rewrite for Apache. More info here: http://httpd.apache.org/docs/1.3/mod/mod_rewrite.html

arbithero
+2  A: 

You need to rewrite the htaccess.

RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

More info: http://codeigniter.com/user_guide/general/urls.html

turbod
A: 

For a more Detailed Explanation have a look at the Codeigniter Wiki

http://codeigniter.com/wiki/mod_rewrite/

Sandy
A: 

You need to use Routing feature in CodeIgniter.

under application/config/routes.php file,

modify the the following line into this:

$route['default_controller'] = 'home';

then follow the guide to remove index.php found here: CodeIgniter URLs

tpae