Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

how can I print url parameters?

0 views
Skip to first unread message

tobias

unread,
Aug 23, 2003, 6:26:38 PM8/23/03
to
I am new in programming with PHP.

I wrote the following code:

file name: output.php

<?php echo $texto; ?>

And I call it on my browser like:
http://localhost/cgt/output.php?texto=testing

The response in my browser is:
Notice: Undefined variable: texto in C:\Inetpub\cgt\output.php on line 1

Can anybody help me?
Lots of thanks.

(you can reply to my email address.)

Hywel Jenkins

unread,
Aug 23, 2003, 9:00:27 PM8/23/03
to
In article <165e4477.0308...@posting.google.com>,
tob...@sabadellpisos.com says...

> I am new in programming with PHP.
>
> I wrote the following code:
>
> file name: output.php
>
> <?php echo $texto; ?>
>
> And I call it on my browser like:
> http://localhost/cgt/output.php?texto=testing
>
> The response in my browser is:
> Notice: Undefined variable: texto in C:\Inetpub\cgt\output.php on line 1

<?php echo $_GET["texto"]; ?>

--
Hywel I do not eat quiche
http://hyweljenkins.co.uk/
http://hyweljenkins.co.uk/mfaq.php

sam

unread,
Aug 24, 2003, 5:17:47 AM8/24/03
to
You have register_globals set to off in your php.ini file.
user $_GET['texto'] instead of $texto.

HTH

"tobias" <tob...@sabadellpisos.com> wrote in message
news:165e4477.0308...@posting.google.com...

0 new messages