Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <link href="https://fonts.googleapis.com/css?family=Muli" rel="stylesheet">
- <link rel="stylesheet" type="text/css" href="../css/style.css">
- </head>
- <?php
- $domainame = $_SERVER['SERVER_NAME'];
- //======================================================================
- //Script time
- //======================================================================
- $time1 = microtime(true);
- error_reporting(E_ALL); // Turn on all errors, warnings and notices for easier debugging
- // Check if the post variable is set:
- if (isset($_POST)) {
- // Check if the key search post variable is set:
- if (isset($_POST["search"])){
- // Define the query:
- $query = htmlspecialchars($_POST['search']);
- }
- }
- //======================================================================
- // For the HTML
- //======================================================================
- //divide string in to array
- $allterms=explode(';', $query);
- //terms in array count
- $termc=sizeof($allterms);
- // a bit nicer represenatation of what we're searching
- $niceeterms = preg_replace('/;/', '', $allterms);
- $niceterms = implode(",",$niceeterms);
- function searchcall(){
- global $niceterms;
- global $termc;
- echo 'Selected terms: '. $niceterms. ".<br>
- Found terms: ".$termc.".<br>
- "."In 5 seconds starting the search." ;
- }
- ?>
- <body>
- <header>
- <div id="title"><h1>Found terms</h1> </div>
- </header>
- <div id="info"><h4> <?php searchcall();?> </h4>
- </div>
- <script>
- setTimeout(function () {
- window.location.href= 'paieska.php'; // the redirect goes here
- },5000);
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement