Love this site? Hate it? Leave us some comments.
*/
*/

Read Post

PHP

Moderators: None (Apply to moderate this forum)
Number of threads: 1402
Number of posts: 4156

This Forum Only
Post New Thread

Report
session Posted by alaatrash on on 14 May 2008 at 8:54 AM
hello......I used :

session_start() ;
session_register('msg') ;

to create a session and I wrote: $_SESSION['msg']="card added" ;
and there is a header in the page to another page, I tryed to output the message like this but it didn't work: echo"$_SESSION['msg']" ;

how can I do that.... and thanks alot
Reply
Report
Re: session Posted by adeydas on on 17 Jun 2008 at 11:52 AM
Did you try session_start() in the next page before echo().

If it gives "Headers already sent" then try:

ob_start()

session_start()
----------etc

ob_flush()


: hello......I used :
:
: session_start() ;
: session_register('msg') ;
:
: to create a session and I wrote: $_SESSION['msg']="card added" ;
: and there is a header in the page to another page, I tryed to output
: the message like this but it didn't work: echo"$_SESSION['msg']" ;
:
: how can I do that.... and thanks alot

Abhishek
http://adeydas.com
Reply




corner
© 1996-2008 CommunityHeaven LLC. All rights reserved. Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
North American business development: Nicolai Wadstrom. Publisher: Lars Hagelin.
Resource Listings