Page 1 of 1

Get all variables and store them in a global file for NEWBIE

Posted: Tue Jul 05, 2005 8:09 am
by ianhull
Can any one of you guys help me with getting all the variables from one page and storing them in a global file

The global file is used as a include file on all my pages.

I am new to php and do not know much about it so any help will be greatly appreciated.

Thanks in advance

Posted: Tue Jul 05, 2005 10:38 am
by pickle
I'm not sure if you can just get all declared variables - you need to reference each one in particular.

Further, I would strongly recommend using a cookie or a session to store any variables you need, rather than storing them in a file. Handling cookies and sessions will also have quite a bit less overhead.

You can store stuff in a cookie simply by calling setcookie().