Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Routeing problem
  • i want to route the request from
    --->    http://localhost/mainsite/public/generalnumber1/idea/idea274
    to
    ---->  http://localhost/mainsite/public/generalnumber/series?batchcode=idea274

    the code which i have use is given below
    <?php

    return array(
        '_root_' => 'welcome/index', // The default route
        '_404_' => '404', // The main 404 route
        'generalnumber2/:idea/:batchcode' => 'Generalnumber/series?batchcode=$2',
    );
    but it is not working i am geting 404  i.e page is not found error
    can some one tell me the correct code for this.

     
  • Fuel doesn't support GET variables in routes. That would work if it would do a secondairy HTTP request with the route result, but it doesn't, route results are resolved internally.

    Also, you have to be careful with using capitals in your routes, by default Fuel is case sensitive, so that might be the cause of the 404 too.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion