You are here: Re: Can a form change session variables? « PHP Programming Language « IT news, forums, messages
Re: Can a form change session variables?

Posted by Jerry Stuckle on 01/13/08 03:08

Kurda Yon wrote:
> Hi,
>
> In the first page I declare a session variable. Than, on the same
> page, I make a form which contains a variable which has the same name
> as the mentioned session variable. Pressing the "submit" button of the
> form I go to the second page which immediately redirects me back to
> the first page (with the "header"). And the mentioned variable does
> NOT have the value which I have specified in the form.
>
> It means, that session does NOT recognize the form variables as
> session variables in spite on the fact that these variables have
> identical names. Is that true?
>

It used to - there is a parm in the php.ini file called register_globals.

In earlier versions, this was enabled and would do what you want.
However, this is a huge security risk and has been disabled by default
in recent versions.

It's simple to get the variable from the session, though.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

 

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

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