• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Routing problem using $_GET query string

#1
[eluser]MABUS[/eluser]
Hi, I need help on CI routing.

The situation is that I have to use $_GET, thus using a query string to transfer from one page to another. Now, my problem is how to route properly.

Here's my scenario ...

1. I have this '$route['^search/?$'], which redirects to 'folder1/controllerOne' .

This basically means that if something like 'search' or 'search/' is on the url, then it will redirect to folder1/controller1.

2. I need '$route[^search\?.*$']' to redirecto to another controller, say folder1/controller2.

This means that if I get something like 'http://domain.com/search?variable=value', then this sould be redirecting to controller2, since search is followed by '?'.

So, how do I do something like this on CI?

Thanks in advance


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


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