Jason put a little snip from the man that he found that works just fine on my pages.
It looks like you increment or change the variable directly in the session register instead of doing it on the page. That sounds suspiciously like what you were trying to tell me. :-) What do you think... On Tue, 29 Jan 2002 12:11:02 +0800, you wrote: >On Tuesday 29 January 2002 06:36, Floyd Baker wrote: > >> Yes I have a c:\tmp directory and I see the session being created in >> it. And the page_view value of 1 after the first increment. The >> editor wants to reload each time I hit the submit button after that >> but the value does not increase beyond 1. It is also the same session >> each time. No new sessions are being created. >> >> I have turned on the log and keep getting undefined_variables for >> those two lines in each page that call $page_view before it's >> incremented, unless I am engaging the $_SESSION call. Then >> $table_view becomes 1 and there are no errors. But the incremented >> value doesn't hold up. >> >> Almost like nothing is happening.., except the *editor* thinks there >> is something going on when looking at the session file?? Like a one >> is being loaded each time. How could that be? Or the original one is >> staying even though an overwrite is being attempted. > >Here's an interesting snippet from the manual: > >The track_vars and register_globals configuration settings influence how the >session variables get stored and restored. > >Note: As of PHP 4.0.3, track_vars is > always turned on. > >If track_vars is enabled and register_globals is disabled, only members of >the global associative array $HTTP_SESSION_VARS can be registered as session >variables. The restored session variables will only be available in the array > $HTTP_SESSION_VARS. > >Try the simple example in the manual: > ><?php >session_register("count"); >$_SESSION["count"]++; >echo "Count is " . $_SESSION["count"]; >?> Wow... That works. Alllll right! You mean you can only increment directly in the session register and *then* pull the value.., instead of pulling it first and then incrementing? Is that the basic concept that I should to keep in mind? I can do that... :0) You're all right Jason. This is a terrific help for me. And I'm definitely going to print a hardcopy of the man... Looks like using the on-line or even the pd on screen isn't working out too well. With the changes going on, this is probably something that will come up again and again for some time to come. Nice to have it figured out, eh? And I'll do some more tests, etc. and put a little follow up here on anything else I see. Floyd >> Now I have uploaded these scripts to my isp and they do not work up >> there either. That is, using his ini, his php 4.0 with >> register_globals on, etc. Could you perhaps test these scripts on >> your machine or create an 'accumulating' routine of your own that >> works? So I can see where the difference might be coming in? > >Your original scripts with the changes I suggested works on my system. -- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]