hi fnds am new one to use php,I' am doing a small project which includes 5 php files the problem is all php files need one data ie object written by the client login for google docs now I need to make that object available to all the 5 files untill user quits the project is there any scope facility in php to make a variable to be accessible by any file???? thank you,
use like this at top of ur page global <variable name> then u can use that variable any where in the page like global <variable name> inlcude "page1.php" inlcude "page2.php" inlcude "page3.php" the <variable name> will be availble to all files
I think you did'nt get my problem clearly right???? k I'll explain you in detail see am using extjs framework to build client side and php to build server side jobs... Now I have a script1.js file that have a button "retrieve files" whenever I click that button it should list out the file names... I have loging.php file functions: 1. login to googledocs. 2.get the docs object through which we can retrieve the uploaded files. this file should be called only once that is at the begining of the project where login requires. another file retreive.php functions: It takes care about retrieve the files name and retruns those to script.js file to display. Here to get the files it needs to use the 'docs' object which is created in the file loging at the begining.... problem is how that docs object available to retrieve.php file untill the user quits the project????