Truncated output from querysring variable
| From: | Alberto Brea | Date: | Fri, 16 May 2003 16:17:43 +0000 |
| Subject: | Truncated output from querysring variable | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-147912@lists.php.net to get a copy of this message | ||
Hi, list. Could you please help me with this:
I have the following string variable "$sql" on page1.php, which I am trying
to print on page2.php. The string and link are as follows:
[PAGE1.PHP]
$sql="SELECT * FROM contacts
WHERE u='$u'
ORDER BY id
DESC LIMIT 10";
print("<td><a target=frame1 href=03frame1.php?u=$u&" .
"inc=updrecord_form&id=$id&sql=$sql" .
"updrecord=contact>upd</a></td>\n");
[PAGE2.PHP]
Now, on this page I validate the variable and try to print it like this:
$sql= $_REQUEST["sql"];
print("Query: " . $sql . "Query ends here<br>");
However, the output is rendered truncated after the first word
("SELECT").This is the output:
Query: SELECTQuery ends here
What could be happening?
TIA
Alberto Brea