You are here: Re: Help with $_POST and $_SERVER['PHP_SELF'] please. « PHP Programming Language « IT news, forums, messages
Re: Help with $_POST and $_SERVER['PHP_SELF'] please.

Posted by Jerry Stuckle on 05/20/06 21:31

Dynamo wrote:
> Many thanks. Apart from a couple of false starts everything is now OK. First
> time I tried your code I simply copied and pasted it and ended up with an
> unknown function error. Although you correctly call it session_start() to begin
> with, in the actual sample code you called it start_session(). Second time I
> tried it I got a couple of warnings that headers had already been sent and that
> the session could not be started. That was because I hadn't called the function
> at the ABSOLUTE beginning of the page. I had
>
> <?php
> include("connect.php");
> session_start();
> ?>
>
> But when I changed it to
>
> <?php
> session_start();
> include("connect.php");
> ?>
>
> Everything was honky dory. I guess a little bit always needs to be left to the
> programmer to sort out eh? :-)
>
> Many thanks to all those that helped with this posting
>
> Dynamo
>
>
>
>
> In article <F9udnZilfvxmhPLZnZ2dnUVZ_uWdnZ2d@comcast.com>, Jerry Stuckle says...
>
>
>>The way I prefer is to store it in the session. Just call session_start() at
>>the beginning of each page where you need sessions (before ANY output -
>>including whitespace - is generated) and store it in the session, i.s.
>>
>> <?php
>> start_session();
>> (perhaps other stuff here, i.e. validation code)
>> $_SESSION['delete'] = $_POST['delete'];
>> ?>
>>
>>Then the next time through you can get it from $_SESSION['delete'].
>>
>
>

Sorry about the function name. I guess I shouldn't post before my first pot of
coffee :-).

--
==================
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

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