sorry if i sound like a perfect idiot in PHP. the books make it sound so easy but when i run their example tutorials, i keep getting all sorts of errors.
Sleipnir, after changing the "bad code" as you advised, i got another error.
Notice: Undefined variable: count in C:\Program...
another question
if i want to set the "register_globals" to ON, where should i change the runtime configuration directive?
the php.ini file or some other files within apache?
Oops.
the problem got worse.
after i tried using your codes, i get this error
Parse error: parse error, unexpected '=' in C:\Program Files\Apache Group\Apache2\htdocs\tutorials\session_count_working.php on line 9
i get the very same error message
"Warning: Your script possibly relies on a session side-effect which existed until PHP 4.2.3. Please be advised that the session extension does not consider global variables as a source of data, unless register_globals is enabled. You can disable this...
Hi, I encountered the very same problem, but with a simpler script.
the codes are as follows:
<?php
// count_me.php
// if session does not yet exist for this user, start one
session_start();
session_register('count');
$count++;
echo "<P> you been here $count times...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.