Sunda Cyber Army


* Sunda Cyber Army 2k17 *
Indonesia Defacer ~


Path : /home/dent/public_html/demo6a/
File Upload :
Current File : /home/dent/public_html/demo6a/results.php

<?php
print_r($_REQUEST);

$host = "webdev.iyaserver.com";
$user = "dent";
$userpw = "";
$db="dent_dvd";

include "../pdloginvariables.php";

$mysql = new mysqli( $host, $user, $userpw, $db );

if($mysql->connect_errno) {
    echo "ERROR in Database connection: ";
    echo $mysql -> connect_error;
    exit();
}

?>

    <h1>Search results:</h1>
    <br>

<?php
$sql = "SELECT * FROM movieView2 WHERE 1=1 ";

if($_REQUEST["title"] != "") {
    $sql .= " AND title LIKE '%" . $_REQUEST["title"] . "%'";
}

if($_REQUEST["rating"] != "ALL") {
    $sql .= " AND rating='" . $_REQUEST["genre"] . "'";
}

if($_REQUEST["genre"] != "ALL") {
    $sql .= " AND genre='" . $_REQUEST["genre"] . "'";
}

echo "<hr>$sql<hr>";

$results = $mysql->query($sql);

if(!$results) {
    echo "ERORR: ". $mysql->error;
    exit();
}

echo "<br><br>Your search returned " . $results->num_rows . " records<hr>";

while($currentrow = $results->fetch_assoc()) {
    echo $currentrow["title"] . "<br>";
}