A JM Posted July 17, 2009 Share Posted July 17, 2009 I have an Iframe variable that I want to be set from a recordset populating my parent form and am having a problem with this. The parent form uses the following as a label: <?php echo htmlentities($row_rstocdetail['formnumber'], ENT_COMPAT, 'utf-8'); ?> I want my Iframe to be able to use the same information but I cant seem to get the variable to pass. Since the form on the parent is not submitted I can't use $_POST so I'm at a bit of a loss... this has to be easy I'm just missing something obvious here. Any help would be appreciated. Thanks. A JM, Quote Link to comment Share on other sites More sharing options...
pengu Posted July 17, 2009 Share Posted July 17, 2009 I hope I'm reading your question right. Could you just put it into a $_SESSION ? Quote Link to comment Share on other sites More sharing options...
A JM Posted July 17, 2009 Author Share Posted July 17, 2009 I'm still pretty new to the game... how would you go about using it? On the parent if (!isset($_SESSION)) { session_start(); } $_SESSION['myvar']='123456'; Then can I simply use the variable on the Iframe? echo "Our color value is ".$_SESSION['myvar']; What happens if the user uses the back button, etc? do I need to worry about clearing the $_SESSION? Thanks. 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.