Apache PHP trouble

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
scottae
Forum Newbie
Posts: 5
Joined: Thu May 01, 2003 7:12 pm
Location: Atlanta, Ga.

Apache PHP trouble

Post by scottae »

Hi everyone......I am a first timer here and new to PHP. I am having a bit of trouble and I'm am a little confused. I have the Apache server installed on my computer and I have it configured to run PHP4. The PHP is working for the most part. But I have trouble trying to pass variables using the POST method. For example.....I followed one of the basic tutorials online to create a simple HTML form that has an input field and a submit button. The form is supposed to send whatever text is in the input field (using the POST method) to another PHP file. The PHP file is supposed to use the variable and display the value of the variable to show it is working properly.

The problem is the variable is not getting set properly. Yet, if I use

$HTTP_POST_VARS["Variable"]

rather than

$Variable

then it works.
But I would like to know why the latter is not working properly on my computer. If it's due to having something configured improperly or if I am doing something wrong, could someone let me know?

Any suggestions would be most appreciated. :)


Scottae
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

please read Sticky: Before Post Read: Concerning Passing Variables in PHP 4.2+
It's not a sticky thread for nothing
scottae
Forum Newbie
Posts: 5
Joined: Thu May 01, 2003 7:12 pm
Location: Atlanta, Ga.

Post by scottae »

Ahhhh yes.........sorry about that. Thanks!!
Post Reply