<!doctype html> <html lang="en"> <head> <meta charset="utf-8"> <title>jQuery UI Dialog - Default functionality</title> <link rel="stylesheet" href="http://code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css"> <script src="http://code.jquery.com/jquery-1.10.2.js"></script> <script src="http://code.jquery.com/ui/1.11.4/jquery-ui.js"></script> <script> $( document ).ready(function() { $("#search").click(function(){ $( "#dialog" ).dialog({ width: 800 }); }); }); </script> </head> <body> <input type="button" style="width: 4.5em;" value="Search" name="" id="search"> <div id="dialog" title="Basic dialog" style="display:none"> <iframe src="search.php" width="800" height="200" style="border:none"></iframe> </div> </body> </html>
<!doctype html> <html> <head> </head> <body> <form action="" method="POST"> search<input type="text" name="key" value = "<?php echo isset($_POST['key'])? $_POST['key'] : ""; ?>"> <input type="submit"> </form> <?php if(isset($_POST['key'])){ echo $_POST['key']; } ?> </body> </html>