Jump to content

Browser Support For Query String ($_Get)


newbornultra

Recommended Posts

Hi there,

I am having a little trouble with a hyperlink containing a query string to another site. On Chrome, it is recognised as a $_GET parameter, but it seems on the others (Firefrox/Safari/IE) it doesn't seem to be picking query string.

 

if (isset($_REQUEST['q'])) {    $rUrl=$_SERVER["HTTP_REFERER"];    echo "<pre>";    echo $rUrl;    $url=parse_url($rUrl);    $host=$url['host'];    echo "</pre>";
}  else {    echo "<pre>";    var_dump($_REQUEST);    echo "</pre>"; }

 

and my test page:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Untitled Document</title></head>
<body><a href="http://domain.com/?q=puXs543543fi7654645n-baztbb65Kim9ra2KDX6F-nnu3z4crnpqFra67IiO54645qFh7iA">Link</a></body></html>

Link to comment
https://forums.phpfreaks.com/topic/271637-browser-support-for-query-string-_get/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.