What should i do to pass variable in the address. Ex: http://www.domain.com/test.php?sth=my test script
Can i pass 'sth' with spaces in between? Or is there a better way to do this
Thanks
hi,
I think this might help u.
$sth="my test script";
/ Have a look at the function urlencode in php.net / $sth=urlencode($sth); http://www.domain.com/test.php?sth=$sth
normally, URL is encoded as follows [space]=%20 = char(32).. eg "sth=my test script" will be(must be) encoded as "sth=my%20test%20script".
check urlencode() function
Thank u all for your prompt reply. Thanks again. KID