RES: [PHP] Very simple session question
| From: | Thiago Pojda | Date: | Mon, 26 May 2008 22:09:55 +0000 |
| Subject: | RES: [PHP] Very simple session question | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-274707@lists.php.net to get a copy of this message | ||
Hi John,
What do you mean about "another program"? Is it something like...
a.php:
<?php
session_start();
$_SESSION["index"]= "value";
echo "call b <a href=\"b.php\">here</a>";
?>
b.php:
<?php
session_start();
var_dump($_SESSION);
?>
... or something else?
Try the example above, if this does not work then you should start looking
at your php.ini for session support, check if it's disabled or something.
Or maybe try using session_write_close() at the end of the scripts, they
might work (if session support is enabled).
Atenciosamente,
www.softpartech.com.br
Thiago Henrique Pojda
Desenvolvimento Web
+55 41 3033-7676
thiago.pojda@softpartech.com.br
Excelência em Softwares Financeiros
-----Mensagem original-----
De: John Allsopp [mailto:john@johnallsopp.co.uk]
Enviada em: segunda-feira, 26 de maio de 2008 18:17
Para: php-general@lists.php.net
Assunto: [PHP] Very simple session question
Hi
I've gone bozzeyed, so I've a simple question for you.
I open session_start() as the first thing, on each page.
I set a session variable using, for instance,
$_SESSION['ACCOUNTemail'] = $email;
The next program, when I var_dump($_SESSION), it shows an empty array.
That program does run session_start() too.
What's obviously wrong, or what's my most likely cause?
Cheers
J
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php