hi all,
i want to store a value in session by using javascript in php.Can any one say me about it, i mean how to store and how to get that in the other php page.
Thanks in advance..

You can do it via AJAX to a php "store_session.php" page and post values to the page, you can then pull values back through "request_session.php" page and use javascript to find the relevant result.

Horrible but works.

Regards

cant we do it without using ajax

What problem are you trying to solve?

That makes providing a solution a lot easier :)

wat i need is i had a projects page in which list of projects are displayed in a table with radio buttons.wen i select a radio button and click submit button it will move to the next page where i can upload and download files in that project but wat happening is wen i click download button the page is getting refresh and the radio button value obtained by post method is also refreshing so is there any way to solve this.

k...

so when you download files you are losing the project page...

the easiest way is to popup the downloading file page into a separate window, that way leaving the project page unaffected

no actually in my projects page projects with radio buttons wil be displayed we can select the project by clicking on radio button so that wil be posted to the next page by post method but wen i did refresh that post(radio button value) is dissappering. i want that posted value to be unchanged even if refreshed.

right ok...

cookies is probably better then...?

or encoded values in the url, so that if the second page is refreshed the URL contains the encoded form data

so how can i do that because i didnt work with cookies. so please..

i think u didnt got my problem.sorry for my poor english. i wil describe it now once again.
i had a projects page and list of projects can be seen with radio buttons. so wen we select a project and click submit we go to the upload page and the value of radio button is send to upload page by url. so wen i upload a file it wil be displayed in a table with each having download link so here is my problem wen i click on the download link popup comes and the value which i am getting by 'url' is refreshing.I want those values remain as it is wen i click download link.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.