• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED]Routes problem?

#1
[eluser]Unknown[/eluser]
Hello,

I have the following issue.

My ci folder is in http://localhost/www/

Everything worked well and then when i inserted some extra routes
$route['designs'] = "posts/get/designs";
$route['designs/tag'] = "posts/get/design/tag";
$route['designs/tag/(:any)'] = "posts/get/design/tag/$1";
$route['designs/(:any)'] = "posts/get/design/$1";

Now i use <?=base_url()?> to get the something like
< a href='&lt;?=base_url()?&gt;designs'>Designs</ a>

When on the home screen the link produces http://localhost/www/designs
But when i am on the page http://localhost/www/designs
The link shows http://localhost/designs
And if i click it then it still works although i there is no www in the url.

The site works fine but i don't want it be accessible without the www.
When site goes live it will be without the www.

Hope it makes sense!

#2
[eluser]Unknown[/eluser]
Found the problem. i loaded the config file in a self created helper and i guess that reseted the base_url that was automatically generated. Solved it by making a new config file and put the config i needed for that helper there!


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


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