fallen_angel21 Posted July 16, 2008 Share Posted July 16, 2008 how can I pass a variable from iframe1 to iframe2? Is that possible? Quote Link to comment Share on other sites More sharing options...
Xurion Posted July 16, 2008 Share Posted July 16, 2008 What exactly are you trying to do? What is interpreting the variables? Quote Link to comment Share on other sites More sharing options...
fallen_angel21 Posted July 16, 2008 Author Share Posted July 16, 2008 I have 2 frames in a page... what I wanted to do is that if they click the link at iframe1, a variable will be passed on iframe2... then the content will appear on iframe2 (content will depend on the passed variable) without the whole page loading again... Quote Link to comment Share on other sites More sharing options...
adam84 Posted July 16, 2008 Share Posted July 16, 2008 function myFunc( newVar ){ window.frames["frame2"].src = 'frame2.php?val='+newVar; } I think something like this should work Quote Link to comment Share on other sites More sharing options...
fallen_angel21 Posted July 16, 2008 Author Share Posted July 16, 2008 ^ok thank you! I'm gonna try this one... Quote Link to comment Share on other sites More sharing options...
juliston Posted July 17, 2008 Share Posted July 17, 2008 Thanks for the information. function myFunc( newVar ){ window.frames["frame2"].src = 'frame2.php?val='+newVar; } I think something like this should work Quote Link to comment Share on other sites More sharing options...
Xurion Posted July 17, 2008 Share Posted July 17, 2008 My question still remains - how are you going to interpret the variables in the second iframe? PHP? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.