Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-19 Thread Anthony Ritter
Thanks again but here's what happens when I run that. The form box appears. I select an option. I hit submit. The page that loads says: Warning: Invalid argument supplied for foreach() in c:\apache\htdocs\session_yyy.php on line 13 I then hit the link: Back to content page. The form box

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-19 Thread John W. Holmes
Anthony Ritter wrote: Thanks again but here's what happens when I run that. The form box appears. I select an option. I hit submit. The page that loads says: Warning: Invalid argument supplied for foreach() in c:\apache\htdocs\session_yyy.php on line 13 I then hit the link: Back to content page.

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-19 Thread Anthony Ritter
Sure. Here it is. There are three scripts. session_1.php: the original form script. session_1a.php: a revised script with a conditional else. session_2.php: the receiving script for the session array variable. Running script 1a and 2 works fine. However the original script 1 and 2 gives me a

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-19 Thread Anthony Ritter
Additinally, upon looking at the session files in: C:/apache/tmp: I get from session file from script session_1a.php: products|s:23:a:1:{i:0;s:6:Tardis;}; ... However, looking at session file from script session_1.php: I get: products|s:2:N;; -- Anthony Ritter [EMAIL

RE: [PHP] =sessions / J. Meloni Textbook=

2003-11-18 Thread Giz
Try changing references to $_SESSION[products] to $_SESSION['products'] -Original Message- From: Anthony Ritter [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 18, 2003 10:49 AM To: [EMAIL PROTECTED] Subject: [PHP] =sessions / J. Meloni Textbook= Using mysql, apache and win98 The

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-18 Thread Burhan Khalid
Anthony Ritter wrote: Using mysql, apache and win98 The following code is from PHP, mySQL and Apache (SAMS) by Julie Meloni. Page 338-339 (hour 16). After choosing my selections in the form box and hitting submit I get: ... Warning: Invalid argument supplied for foreach() in

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-18 Thread CPT John W. Holmes
Anthony Ritter wrote: The following code is from PHP, mySQL and Apache (SAMS) by Julie Meloni. [snip] if (isset($_POST[form_products])) { if (!empty($_SESSION[products])) { $products = array_unique( array_merge(unserialize($_SESSION[products]), $_POST[form_products]));

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-18 Thread Anthony Ritter
Thanks John and others. I'm using the script and no values show up in the page: session_bb.php after I submit the values in the select form. If somebody would like to test both scripts (session_aa.php and session_bb.php) and get back to me I would be grateful. As I said, these were from her

Re: [PHP] =sessions / J. Meloni Textbook=

2003-11-18 Thread John W. Holmes
Anthony Ritter wrote: I'm using the script and no values show up in the page: session_bb.php after I submit the values in the select form. If somebody would like to test both scripts (session_aa.php and session_bb.php) and get back to me I would be grateful. I think you're using a crappy book...