You are here: Re: [PHP] Re: Authentication fails - problem line found « PHP « IT news, forums, messages
Re: [PHP] Re: Authentication fails - problem line found

Posted by John Swartzentruber on 03/04/05 00:44

I stripped down my original script until it started receiving POST data,
then I kept modifying it until I figured out where the problem was. I
found it, but I'm still as clueless as every.

To summarize: I have a form that posts to the same script that contains
the form. In its original state, when the script is called after I
submit the form data, the $_POST[] data is completely empty and the
_SERVER variable that indicates the type of data is set to "GET".

In the script is the following code:

if (IsSet($_POST["action"])) {
// $action = $_POST["action"];
} else {
$action = $_GET["action"];
}


Normally the second line is not commented. When I comment out that line,
then the $_POST array has all of the data I would expect it to. When it
is not commented, then it does not work.

Just to make sure that I am really confused, this bit of code is *after*
the call to var_dump($_POST), but *before* the code that creates the form.

Does anyone have any ideas about why setting this variable has such a
large and seemingly unrelated affect?

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация