Page 1 of 1

Passing data to a php script

Posted: Mon May 07, 2007 7:31 pm
by klure177
I am trying to pass a text string to a php script like this

<img src="create_image.php?text=Testmessage">

but the string never gets passed to the script. The script "create_image.php" creates an image and I want to place some text on it. I copied the code out of Lerdorf's book "Programming PHP". Does it matter that I am using PHP5?

Posted: Mon May 07, 2007 8:03 pm
by volka
If the book says $text use $_GET['text'] instead and search for a more recent book/web tutorial.
see http://de2.php.net/manual/en/security.globals.php

Posted: Tue May 08, 2007 10:16 am
by klure177
That fixed it. Thanks.