View Full Version : Pop-up selections values display

04-30-2009, 09:50 PM
I am new to PHP and would like to ask if the following makes sense; that is, is this the best way to handle the requirement. I have a display that contains certain database fields, and when the user clicks a button another window will pop-up from which selections can be made. Those selections then need to be added to the first screen.

My plan is to use session data. The selections from the pop-up will be saved in sessions, and the first screen will load data from the database, and then additionally from any saved session data.

But, I donít think this will necessarily work with a pop-up. Seems like I will have to redirect to another display for selections and after selections are made (or not) the original display is also redirected to from the selections display.

Maybe PHP is not the right way to go, or is it?


04-30-2009, 10:04 PM
i don't think i understood you
do you mean something like this: http://www.w3schools.com/Dom/tryit.asp?filename=try_dom_httpsuggest

04-30-2009, 10:27 PM
I thought about that (is that Ajax?). But not really. The selection would come from a pop-up screen that lists available selections. Then, when that window closes the items selected would be added to the first screen displayed.

04-30-2009, 10:58 PM
so you have 2 php pages.

main page contain the selected items read from cookies\db what you chose
and the pop-up page contain the select with some options that you can add and will write to cookies\db

after you open the pop-up and submit what you want, do a refresh to the main page with js to show the user his items.

05-01-2009, 02:08 PM
Do a refresh? Do you mean provide a refresh button that the user must click?

05-01-2009, 06:13 PM
I think IFRAMES may be the way to go.
I tried a quick test, and it might work...