Connecting Tech Pros Worldwide Help | Site Map

Change page in other frame on load from variables?

Newbie
 
Join Date: Nov 2006
Posts: 17
#1: Oct 9 '07
Hey all, Im trying to create a thing that will essentially allow me to use tabbed browsing within a website using php sessions to store the different opened pages.

To do this, im using two frames, 'id'ed menu and main
The menu is to hold the main code for listing the open tabs and creating new ones.

My question, can i use a javascript onload function to load a page into the 'main' frame from the menu.php page in the menu frame?

Its simply to load the default page at the start which i could do from within the <frameset><frame> tag src attribute but incase they reload the page, i want the opened tabs to stay the same including the defaultly opened on at the start assuming that that will be the first one they change.
acoder's Avatar
Site Moderator
 
Join Date: Nov 2006
Location: UK
Posts: 14,581
#2: Oct 9 '07

re: Change page in other frame on load from variables?


Can you post the code you have so far so we can work with that.

See this article. Use location.href to change the page.
Newbie
 
Join Date: Nov 2006
Posts: 17
#3: Oct 10 '07

re: Change page in other frame on load from variables?


Yea, that would look to be what I want to do, thanks!

will put some code up anyway so you can see what im at, but need to write a bit more to actually make it work!

(and the php sessions decided they didn't want to work on my computer after a reboot, so will have to get that sorted before writing and testing further)
Reply