Welcome Guest, Not a member yet? Register   Sign In
Rewrite help.
#6

[eluser]tomcode[/eluser]
Do You need to pass the whole (1-agricultura-pescuit-si-silvicultura.html), passing only the id (1) does it, too.

If yes though, You could do :
Code:
$cat_parts = explode('-', $categorie);

if(isset($cat_parts[0]) && is_numeric($cat_parts[0]))
{
    $id = $cat_parts[0];
}
else show_404();


Messages In This Thread
Rewrite help. - by El Forum - 08-12-2009, 04:53 PM
Rewrite help. - by El Forum - 08-12-2009, 05:35 PM
Rewrite help. - by El Forum - 08-12-2009, 07:05 PM
Rewrite help. - by El Forum - 08-12-2009, 10:26 PM
Rewrite help. - by El Forum - 08-13-2009, 02:45 AM
Rewrite help. - by El Forum - 08-13-2009, 03:02 AM
Rewrite help. - by El Forum - 08-13-2009, 03:43 AM



Theme © iAndrew 2016 - Forum software by © MyBB