zour1el Posted June 7, 2011 Share Posted June 7, 2011 I need help getting a grasp on something..... I have a page with a simple form (form.html) on it that calls a php page (searching.php) that searches a mysql database. I have to use iframes or embed the results (that is currently echoed onto the php page) So this of course shows the contents of the mysql dataset cause of the embed is execing the php. How can I output the results to a 3rd page so i can embed it without pre-executing the php. It is in a liferay portal and PHP is not supported on the instance. It all reality what i would REALLY like is Form then below it have the results to be visible....... Any help would be appreciated Quote Link to comment https://forums.phpfreaks.com/topic/238702-form-on-html-to-php-that-queries/ Share on other sites More sharing options...
zour1el Posted June 7, 2011 Author Share Posted June 7, 2011 Just for clarity.... Form.html search box that calls search.php by an onclick. Search.php queries mysql dbase. and echos out the results -------------------------------------------- Because of the portal and there is no php intergration (GRRRRRR) I have to embed or use iframes. so when embedding or iframing the page shows error Notice: Undefined index: term in search.php on line 5 and it displays the contents of the dbase I was trying to figure away so I didnt have to embed the search.php, that way the error and contents wouldnt be present. ---------------------------------------------------------------------- In a perfect world I would love to have some pointers or ideas on how to have from and the results output on the same page so it is seamless (not a full page refresh) Quote Link to comment https://forums.phpfreaks.com/topic/238702-form-on-html-to-php-that-queries/#findComment-1226637 Share on other sites More sharing options...
jnvnsn Posted June 7, 2011 Share Posted June 7, 2011 I don't know if this is what you mean but give it a try. http://www.trirand.com/blog/jqgrid/jqgrid.html Quote Link to comment https://forums.phpfreaks.com/topic/238702-form-on-html-to-php-that-queries/#findComment-1226652 Share on other sites More sharing options...
zour1el Posted June 8, 2011 Author Share Posted June 8, 2011 I was wondering is there away to pass the data from the search.php to a different html page via javascript? Quote Link to comment https://forums.phpfreaks.com/topic/238702-form-on-html-to-php-that-queries/#findComment-1227188 Share on other sites More sharing options...
spiderwell Posted June 8, 2011 Share Posted June 8, 2011 it can be done, but its not really a proper method. you have to echo out javascript in php. <?php $myphpvar = "im a php variable"; echo "<SCRIPT>"; echo "alert('" . $myphpvar . "');"; echo "</SCRIPT>"; ?> Quote Link to comment https://forums.phpfreaks.com/topic/238702-form-on-html-to-php-that-queries/#findComment-1227197 Share on other sites More sharing options...
zour1el Posted June 8, 2011 Author Share Posted June 8, 2011 What would be a good method to pass the data set from the php to another page....... And thank you for reply Spiderwell Quote Link to comment https://forums.phpfreaks.com/topic/238702-form-on-html-to-php-that-queries/#findComment-1227209 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.