İptal Edildi

Mysql Count Fix

Here is the secure fix.

$dbHost = "DBHOST";

$db = "DBNAMEHERE";

$user = "DBUSER";

$pass = "DBPASS";

$con = new PDO('mysql:host=$dbHost;dbname=$db', $user, $pass);

/*Query1*/

$lastweek = date( "Y-m-d", strtotime ("-2 day" ) ) ;

$prepared = $con->prepare("SELECT Count(*) AS total FROM jobs WHERE DatePosted >= ?");

$newjob_count = $prepared->execute(array($lastweek));

/*Query2*/

$yesterday = date( "Y-m-d", strtotime ("-8 day" ) ) ;

$prepared = $con->prepare("SELECT Count(*) AS total FROM jobs WHERE DatePosted >= ?");

$newweekjob_count = $prepared->execute(array($yesterday));

/*Query3*/

$job_count = $con->query("SELECT Count(*) AS total FROM jobs");

/*Query4*/

$business = $con->query("SELECT Count(*) AS total FROM jobs WHERE PositionType='Business Jobs'");

/*Query5*/

$writing = $con->query("SELECT Count(*) AS total FROM jobs WHERE PositionType='Writing Jobs'");

I removed all of the vulnerabilities as well. All you need to fill in is the dbhost, dbname, dbuser, and dbpass.

If you need anymore help, feel free to contact me. Can you please send the $20?

Beceriler: HTML, Linux, MySQL, PHP, Web Sitesi Testi

Daha fazlasını görün: writing fix, the writing fix, n.y. jobs, n.y.c. jobs, free writing jobs, business writing jobs, pdo, fix mysql query, fix query, pass query, pdo mysql, day count, fix array mysql, import xml mysql php cron job, count mysql, php mysql part time job, php mysql programmer needing job, mysql host, mysql contact db, host fix, fix vulnerabilities, mysql count, secure mysql, php mysql website creation job hourly rates, mysql array

İşveren Hakkında:
( 1 değerlendirme ) Loganville, United States

Proje NO: #4450176

0 freelancers are bidding on average $ for this job

rkomar

Hired by the Employer

1 gün içinde 30$ USD
(0 Değerlendirme)
0.0