HEX
Server: Apache
System: Linux darrell.nocdirect.com 4.18.0-513.18.2.el8_9.x86_64 #1 SMP Sat Mar 30 06:10:41 EDT 2024 x86_64
User: joderbya (1358)
PHP: 8.0.30
Disabled: NONE
Upload Files
File: /home/joderbya/public_html/foiroubado.com/indexbkup20180324.php
<?php
	error_reporting(E_ALL);
	ini_set('display_errors', 1);

	session_start(); // this MUST be called prior to any output including whitespaces and line breaks!

	$GLOBALS['DEBUG_MODE'] = 1;
	// CHANGE TO 0 TO TURN OFF DEBUG MODE
	// IN DEBUG MODE, ONLY THE CAPTCHA CODE IS VALIDATED, AND NO EMAIL IS SENT

	$GLOBALS['ct_recipient']   = 'YOU@EXAMPLE.COM'; // Change to your email address!  Make sure DEBUG_MODE above is 0 for mail to send!
	$GLOBALS['ct_msg_subject'] = 'Securimage Test Contact Form';
?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<meta name="viewport" content="width=device-width, initial-scale=1.0">
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>Moçambique Lista Negra</title>
	<link rel="stylesheet" type="text/css" href="view.css" media="all">
	<script type="text/javascript" src="view.js"></script>
	
	<style type="text/css">

a:hover {
	color: yellow;
	text-decoration: underline;
}
.thumbnails img {
	width:60px;
	height: 50px;
	border: 4px solid #555;
	padding: 1px;
	margin: 0 10px 5px 0;
}

.thumbnails img:hover {
	border: 4px solid #00ccff;
	cursor:pointer;
}

.preview img {
	border: 4px solid #444;
	padding: 1px;
	width: 800px;
}

</style>
	
	<script>
		function valueChanged(v)
		{
			if (v == "automovel")
				automovel();
			if (v == "bicicleta")
				bicicleta();
			if (v == "motorizada")
				automovel();
			if (v == "telemovel")
				telemovel();
			if (v == "barco")
				automovel();
		}
		
		function motorTyping()
		{
			if(document.getElementById("element_3").value.length > 0) {
			document.getElementById("element_2").disabled = true;
			document.getElementById("element_2").value = "";
			document.getElementById("element_2").style.color = "#AAA";
			document.getElementById("element_2").style.background = "#F5F5F5";
			
			document.getElementById("element_4").disabled = true;
			document.getElementById("element_4").value = "";
			document.getElementById("element_4").style.color = "#AAA";
			document.getElementById("element_4").style.background = "#F5F5F5";
			
			document.getElementById("element_5").disabled = true;
			document.getElementById("element_5").value = "";
			document.getElementById("element_5").style.color = "#AAA";
			document.getElementById("element_5").style.background = "#F5F5F5";
			}
			else
			automovel();
		}
		
		function quadroTyping()
		{
			if(document.getElementById("element_4").value.length > 0) {
			document.getElementById("element_2").disabled = true;
			document.getElementById("element_2").value = "";
			document.getElementById("element_2").style.color = "#AAA";
			document.getElementById("element_2").style.background = "#F5F5F5";
			
			document.getElementById("element_3").disabled = true;
			document.getElementById("element_3").value = "";
			document.getElementById("element_3").style.color = "#AAA";
			document.getElementById("element_3").style.background = "#F5F5F5";
			
			document.getElementById("element_5").disabled = true;
			document.getElementById("element_5").value = "";
			document.getElementById("element_5").style.color = "#AAA";
			document.getElementById("element_5").style.background = "#F5F5F5";
			}
			else
							if(document.getElementById("element_7").value == "bicicleta")
					bicicleta();
				else
					automovel();
		}
		
		function matriculaTyping()
		{
			if(document.getElementById("element_5").value.length > 0) {
			document.getElementById("element_2").disabled = true;
			document.getElementById("element_2").value = "";
			document.getElementById("element_2").style.color = "#AAA";
			document.getElementById("element_2").style.background = "#F5F5F5";
			
			document.getElementById("element_3").disabled = true;
			document.getElementById("element_3").value = "";
			document.getElementById("element_3").style.color = "#AAA";
			document.getElementById("element_3").style.background = "#F5F5F5";
			
			document.getElementById("element_4").disabled = true;
			document.getElementById("element_4").value = "";
			document.getElementById("element_4").style.color = "#AAA";
			document.getElementById("element_4").style.background = "#F5F5F5";
			}
			else
			automovel();
		}
		
		function serieTyping()
		{
			if(document.getElementById("element_2").value.length > 0) {
			document.getElementById("element_5").disabled = true;
			document.getElementById("element_5").value = "";
			document.getElementById("element_5").style.color = "#AAA";
			document.getElementById("element_5").style.background = "#F5F5F5";
			
			document.getElementById("element_3").disabled = true;
			document.getElementById("element_3").value = "";
			document.getElementById("element_3").style.color = "#AAA";
			document.getElementById("element_3").style.background = "#F5F5F5";
			
			document.getElementById("element_4").disabled = true;
			document.getElementById("element_4").value = "";
			document.getElementById("element_4").style.color = "#AAA";
			document.getElementById("element_4").style.background = "#F5F5F5";
			}
			else {
				if(document.getElementById("element_7").value == "telemovel")
					telemovel();
				else
					bicicleta();
			}
		}
		
	
		function resetForm()
		{
			document.getElementById("element_2").disabled = false;
			document.getElementById("element_3").disabled = false;
			document.getElementById("element_4").disabled = false;
			document.getElementById("element_5").disabled = false;
			
			//document.getElementById("element_2").style.color = "none";
			document.getElementById("element_2").style.background = "white";
			//document.getElementById("element_3").style.color = "none";
			document.getElementById("element_3").style.background = "white";
			//document.getElementById("element_4").style.color = "none";
			document.getElementById("element_4").style.background = "white";
			//document.getElementById("element_5").style.color = "none";
			document.getElementById("element_5").style.background = "white";
		}

		function automovel()
		{
			resetForm();
			document.getElementById("element_2").disabled = true;
			document.getElementById("element_2").value = "";
			document.getElementById("element_2").style.color = "#AAA";
			document.getElementById("element_2").style.background = "#F5F5F5";
		}
		
		function telemovel()
		{
			resetForm();
			document.getElementById("element_3").disabled = true;
			document.getElementById("element_3").value = "";
			document.getElementById("element_3").style.color = "#AAA";
			document.getElementById("element_3").style.background = "#F5F5F5";
			
			document.getElementById("element_4").disabled = true;
			document.getElementById("element_4").value = "";
			document.getElementById("element_4").style.color = "#AAA";
			document.getElementById("element_4").style.background = "#F5F5F5";
			
			document.getElementById("element_5").disabled = true;
			document.getElementById("element_5").value = "";
			document.getElementById("element_5").style.color = "#AAA";
			document.getElementById("element_5").style.background = "#F5F5F5";
		}
		
		function bicicleta()
		{
			resetForm();
			document.getElementById("element_3").disabled = true;
			document.getElementById("element_3").value = "";
			document.getElementById("element_3").style.color = "#AAA";
			document.getElementById("element_3").style.background = "#F5F5F5";
			
			
			document.getElementById("element_5").disabled = true;
			document.getElementById("element_5").value = "";
			document.getElementById("element_5").style.color = "#AAA";
			document.getElementById("element_5").style.background = "#F5F5F5";
		}
	</script>

</head>
<body id="main_body" onload="automovel()">
	<img id="top" src="top.png" alt="">
	<div id="form_container">
		<div id="topBar">
			<img id="flag" src="flag.png" width="30" height="20" alt="">
			<div id="whatsapp"><a href="http://www.foiroubado.com">
				<div id="icon">
					<img src="whatsapp.png" width="25" height="25" alt="">
				</div>
				<div id="lab1">
					<a href="https://api.whatsapp.com/send?phone=258841100016" style="color:red; text-decoration:none;">Reportar!!!</a>
				</div>
				<div id="lab2">
					<a href="https://api.whatsapp.com/send?phone=258841100016" style="color:green; text-decoration:none;">+258 84 110 0016</a>
				</div></a>
			</div>
		</div>
	<div id="content">

	<?php
	$valid = 0;
	process_si_contact_form(); // Process the form, if it was submitted
	if (isset($_SESSION['ctform']['error']) &&  $_SESSION['ctform']['error'] == true): /* The last form submission had 1 or more errors */$valid = 0; ?>
	<?php
	elseif (isset($_SESSION['ctform']['success']) && $_SESSION['ctform']['success'] == true): /* form was processed successfully */
		$valid = 1; include("Pesqform.php");
	endif;
	if ($valid == 0) {?>
		<form id="form_47822" name="submit" class="appnitro"  method="post" action="<?php echo htmlspecialchars($_SERVER['REQUEST_URI'] . $_SERVER['QUERY_STRING']) ?>" id="contact_form">
			<input type="hidden" name="do" value="contact">
			<div class="form_description">
			<h2>Moçambique Lista Negra</h2>
			<p>Roubados em Moçambique</p>
		</div>						
			<ul >
			<h3>Selecione o Tipo de Objecto </h3>
			<p></p>
		<li id="li_7" >
		<label class="description" for="element_7">Tipo </label>
		<div>
		<select onchange="valueChanged(this.value)" class="element select medium" id="element_7" name="element_7">
			<option value="automovel" selected="selected">Automóvel</option>
			<option value="bicicleta">Bicicleta</option>
			<option value="motorizada">Motorizada</option>
			<option value="telemovel">Telemóvel</option>
			<option value="barco">Barco</option>
		</select>
		</div> 
		</li>		<li class="section_break">
			<h3>Indicar Apenas um dos Seguintes Números</h3>
			<p></p>
		</li>		<li id="li_2" >
		<label class="description" for="element_2">Número de Série </label>
		<div>
			<input id="element_2" name="element_2" class="element text medium" onkeyup="serieTyping()" type="text" maxlength="255" value=""/> 
		</div> 
		</li>		<li id="li_3" >
		<label class="description" for="element_3">Número do Motor </label>
		<div>
			<input id="element_3" name="element_3" class="element text medium" onkeyup="motorTyping()" type="text" maxlength="255" value=""/> 
		</div> 
		</li>		<li id="li_4" >
		<label class="description" for="element_4">Número do Quadro </label>
		<div>
			<input id="element_4" name="element_4" class="element text medium" onkeyup="quadroTyping()" type="text" maxlength="255" value=""/> 
		</div> 
		</li>		<li id="li_5" >
		<label class="description" for="element_5">Matrícula </label>
		<div>
			<input id="element_5" name="element_5" class="element text medium" onkeyup="matriculaTyping()" type="text" maxlength="255" value=""/> 
		</div> 
		</li>
		<?php // show captcha HTML using Securimage::getCaptchaHtml()
			  require_once 'securimage.php';
			  $options = array();
			  $options['input_name']             = 'ct_captcha'; // change name of input element for form post
			  $options['disable_flash_fallback'] = false; // allow flash fallback

			  if (!empty($_SESSION['ctform']['captcha_error'])) {
				// error html to show in captcha output
				$options['error_html'] = $_SESSION['ctform']['captcha_error'];
			  }
			  echo "<div id='captcha_container_1'>\n";
			  echo Securimage::getCaptchaHtml($options);
			  echo "\n</div>\n";
			?>
		<li class="buttons">
		<input type="hidden" name="form_id" value="47822" />
		<input id="saveForm" class="button_text" type="submit" name="submit" value="Procurar" style="border-style:solid;"/>
		</li>
			</ul>
		</form>	
	<?php
	}
	?>
	</div>
        <div id="footer">
			Powered by <a href="http://www.foiroubado.com">foi roubado</a>
		</div>
	</div>
	<img id="bottom" src="bottom.png" alt="">
	</body>
</html>


<?php

// The form processor PHP code
function process_si_contact_form()
{

  $_SESSION['ctform'] = array(); // re-initialize the form session data

  if ($_SERVER['REQUEST_METHOD'] == 'POST' && @$_POST['do'] == 'contact') {
  	// if the form has been submitted
    foreach($_POST as $key => $value) {
      if (!is_array($key)) {
      	// sanitize the input data
        if ($key != 'ct_message') $value = strip_tags($value);
        $_POST[$key] = htmlspecialchars(stripslashes(trim($value)));
      }
    }
	//echo 'kevin: '.@$_POST['element_5'];
    $name    = @$_POST['ct_name'];    // name from the form
    $email   = @$_POST['ct_email'];   // email from the form
    $URL     = @$_POST['ct_URL'];     // url from the form
    $message = @$_POST['ct_message']; // the message from the form
    $captcha = @$_POST['ct_captcha']; // the user's entry for the captcha code
    $name    = substr($name, 0, 64);  // limit name to 64 characters
    $errors = array();  // initialize empty error array

    if (isset($GLOBALS['DEBUG_MODE']) && $GLOBALS['DEBUG_MODE'] == false) {
      // only check for errors if the form is not in debug mode

      if (strlen($name) < 3) {
        // name too short, add error
        $errors['name_error'] = 'Your name is required';
      }

      if (strlen($email) == 0) {
        // no email address given
        $errors['email_error'] = 'Email address is required';
      } else if ( !preg_match('/^(?:[\w\d-]+\.?)+@(?:(?:[\w\d]\-?)+\.)+\w{2,63}$/i', $email)) {
        // invalid email format
        $errors['email_error'] = 'Email address entered is invalid';
      }

      if (strlen($message) < 20) {
        // message length too short
        $errors['message_error'] = 'Your message must be longer than 20 characters';
      }
    }

    // Only try to validate the captcha if the form has no errors
    // This is especially important for ajax calls
    if (sizeof($errors) == 0) {
      require_once dirname(__FILE__) . '/securimage.php';
      $securimage = new Securimage();

      if ($securimage->check($captcha) == false) {
        $errors['captcha_error'] = '<span style="color:red"><br>Codigo de segurança incorrecto<br></span>';
      }
    }

    if (sizeof($errors) == 0) {
      // no errors, send the form
      $time       = date('r');
      $message = "A message was submitted from the contact form.  The following information was provided.<br /><br />"
                    . "<em>Name: $name</em><br />"
                    . "<em>Email: $email</em><br />"
                    . "<em>URL: $URL</em><br />"
                    . "<em>Message:</em><br />"
                    . "<pre>$message</pre>"
                    . "<br /><br /><em>IP Address:</em> {$_SERVER['REMOTE_ADDR']}<br />"
                    . "<em>Time:</em> $time<br />"
                    . "<em>Browser:</em> {$_SERVER['HTTP_USER_AGENT']}<br />";

      $message = wordwrap($message, 70);

      if (isset($GLOBALS['DEBUG_MODE']) && $GLOBALS['DEBUG_MODE'] == false) {
      	// send the message with mail()
        mail($GLOBALS['ct_recipient'], $GLOBALS['ct_msg_subject'], $message, "From: {$GLOBALS['ct_recipient']}\r\nReply-To: {$email}\r\nContent-type: text/html; charset=UTF-8\r\nMIME-Version: 1.0");
      }

      $_SESSION['ctform']['timetosolve'] = $securimage->getTimeToSolve();
      $_SESSION['ctform']['error'] = false;  // no error with form
      $_SESSION['ctform']['success'] = true; // message sent
    } else {
      // save the entries, this is to re-populate the form
      $_SESSION['ctform']['ct_name'] = $name;       // save name from the form submission
      $_SESSION['ctform']['ct_email'] = $email;     // save email
      $_SESSION['ctform']['ct_URL'] = $URL;         // save URL
      $_SESSION['ctform']['ct_message'] = $message; // save message

      foreach($errors as $key => $error) {
      	// set up error messages to display with each field
        $_SESSION['ctform'][$key] = "<span class=\"error\">$error</span>";
      }
      $_SESSION['ctform']['error'] = true; // set error floag
    }
  } // POST
}
$_SESSION['ctform']['success'] = false; // clear success value after running