Posted by frizzle on 05/29/06 13:41
Bent Stigsen wrote:
> frizzle wrote:
> [snip]
> > Now i have this:
> > function DefineLoc(){
> > $loc = explode('/', trim( $_SERVER['QUERY_STRING'], '/' ) );
> > return $loc;
> > };
> >
> > But that's also not as it should be but fixes the trailing problem.
>
> I don't think I quite understand what you want.
>
> Can you give an example value of $_SERVER['QUERY_STRING'], and how the
> array returned from DefineLoc should look like.
>
>
> /Bent
$_SERVER['QUERY_STRING'] =
'/artists/nirvana/mtv_unplugged/about_a_girl.html'
$array[0] => artists
$array[1] => nirvana
$array[2] => mtv_unplugged
$array[3] => about_a_girl.html
$_SERVER['QUERY_STRING'] = '/artists/nirvana/mtv_unplugged/'
$array[0] => artists
$array[1] => nirvana
$array[2] => mtv_unplugged
$array[3] => NULL
$_SERVER['QUERY_STRING'] = '/artists/nirvana/mtv_unplugged'
$array[0] => artists
$array[1] => nirvana
$array[2] => mtv_unplugged
$array[3] => NULL
$_SERVER['QUERY_STRING'] = '/artists//mtv_unplugged/'
$array[0] => artists
$array[1] => NULL
$array[2] => mtv_unplugged
$array[3] => NULL
I hope you understand what i mean/want.
Frizzle.
Navigation:
[Reply to this message]
|