• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Clean URLs

I was having some issues with clean urls, but came up with a solution and thought I'd share it. First make a 2nd .htaccess outside of the application directory in the web root directory. Then make the edits here: http://pastebin.com/1gxw1U6E

NOTICE: Make sure you leave the original .htaccess file alone that is in your application directory. Failing to do so will expose your helpers, controllers, etc.

You also want to make sure you enabled mod rewrite in your httpd.conf apache configuration file as well as change line 29ish in config.php to read:

$config['index_page'] = '';

You just opened up a large security hole. You should NOT remove the htaccess protecting the /application directory as you stated. If you do, people will have direct access to your libraries, models, views, controllers, helpers, config settings and anything else, which they shouldn't have access to. See the user guide for how to do this properly.

All you should do is create a NEW htaccess like you mentioned in the root directory and leave the default htaccess files protecting the /application and /system directories alone! Please fix your guide before you steer people in the WRONG direction.

Well, this is for local development only, but I see your point. I was more focused on getting things working right and forgot that the original .htaccess file says Deny from all on the first line. I'll make sure I fix that, but thankfully there is no guide just what I've posted on here so far so that's a bonus. I'll edit my post. Thanks.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

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