Link to home
Start Free TrialLog in
Avatar of mhoggatt1
mhoggatt1

asked on

JSRS Select Demo result.php

I downloaded the 'Select Demo" from this website -

http://www.ashleyit.com/rs/jsrs/select/php/select.php

Is there a way to have the result.php come up in the right frame of a 2 frame vertical split ? For example, if I select a Make?Model?option in the left frame, the list of options would be printed in the right froame ? Actuallly I only need to know how to have any page come up in the right frame (I can print out the options).
Thanks,
Michael
ASKER CERTIFIED SOLUTION
Avatar of archrajan
archrajan

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of archrajan
archrajan

See a simple example here

http://www.archanapatchirajan.com/IFRAMEFORMSUBMIT.html

when u click submit the action page opens in the right frame
Avatar of mhoggatt1

ASKER

Hi archrajan,
   This is basically what I need. I viewed the source but there wasn't any to view. Could you provide sample code with my above script to show me how it works. I'm not far enough along in JS to know what I'm doing.
Thanks,
Michael
I forgot the select.php script. Here it is -

<html>
<head>
  <title>JSRS Select Demo</title>
  <script language="javascript" src="jsrsClient.js"></script>
  <script language="javascript" src="selectphp.js"></script>
  <style>
    body{background:#dddddd;text-align:center;}
    #sel {width:100%;margin: 0px auto 0px auto;}
    #show {background-color:darkgray;width:80%;height:45px;text-align:center;margin-top:15px;padding-top:10px;}
  </style>
</head>
<?php
  $book = isset($_POST['lstMake']) ? $_POST['lstMake'] : -99;
  $chapter = isset($_POST['lstModel']) ? $_POST['lstModel'] : -99;
  $verse = isset($_POST['lstOptions']) ? $_POST['lstOptions'] : -99;
?>
<body onload="preselect('<?php echo $book;?>', '<?php echo $chapter;?>', '<?php echo $verse;?>', 1);" onhelp="jsrsDebugInfo();return false;">
<h2>JSRS Select Box Filling Demo - page #1</h2>
<form name="QForm" method="post" action="select.php">
<div id="sel">
<table class="normal" width="575" BORDER="0" CELLSPACING="2" CELLPADDING="2" VALIGN="TOP">
<?php
  SelectBox ("Book",    "lstMake");    
  SelectBox ("Chapter",   "lstModel");    
  SelectBox ("Verse", "lstOptions");  
?>
</table>
<div id="show">
  <input type="submit" name="cmdSubmit" value="Submit" id="cmdSubmit" title="Show selects with preselected values" style="" /><br />
 
</div>
</div>
</form>

</body>
</html>
<?php

function SelectBox( $Label, $selectName ){
  ?>
  <tr ALIGN="LEFT">
    <td width="15%"><?php echo $Label ?></td>
    <td align="left">
      <select name="<?php echo $selectName ?>">
        <option></option><option></option><option></option>
        <option>--------- Not Yet Loaded ---------</option>
      </select>
    </td>
  </tr>
<?php
}
?>

archrajan,
   I finally figured out what you were saying in your anser. It works fine now.
Thanks,
Michael
Is it, anyway i had half written a sample for u...
i will post it when i get back home
Sure that would be fine. Thanks to all the experts at EE I'm getting closer to finishing my website. I couldn't do it without the help.
Thanks,
Michael
Hi archrajan,
    Justchecking to see if You've finished the select box vor me. I'm just about ready to use it in my next project.
Thanks,
Michael