Bravo List
Register
Go Back   > Bravo List > Source Code > Archived Trackers > Project U-232
Reply
  #1  
Old 19th September 2022, 10:44
hax0r hax0r is offline
Banned
 
Join Date: Sep 2022
Posts: 12
Smile Where Function
$where = where ($_SERVER["SCRIPT_FILENAME"], $row["id"], 0);
SQL_Query_exec("UPDATE users SET last_access='" . get_date_time() . "', ip=".sqlesc($ip).", page=".sqlesc($where)." WHERE id=" . $row["id"]);


function where ($scriptname = "index", $userid, $update=1){
if (!is_valid_id($userid))
die;
if (preg_match("/torrents-details/i", $scriptname))
$where = "Browsing Torrents Details (ID: $_GET[id])...";
elseif (preg_match("/torrents.php/i", $scriptname))
$where = "Browsing Torrents...";
elseif (preg_match("/account-details/i", $scriptname))
$where = "Browsing Account Details (ID: $_GET[id])...";
elseif (preg_match("/torrents-upload/i", $scriptname))
$where = "Uploading Torrent..";
elseif (preg_match("/account/i", $scriptname))
$where = "Browsing User Control Panel...";
elseif (preg_match("/torrents-search/i", $scriptname))
$where = "Searching Torrents...";
elseif (preg_match("/forums/i", $scriptname))
$where = "Browsing Forums...";
elseif (preg_match("/index/i", $scriptname))
$where = "Browsing Homepage...";
else
$where = "Unknown Location...";

if ($update) {
$query = sprintf("UPDATE users SET page=".sqlesc($where)." WHERE id ='%s'", mysqli_real_escape_string($GLOBALS["DBconnector"],$userid));
$result = SQL_Query_exec($query);
}
return $where;
}
Reply With Quote
  #2  
Old 6th October 2022, 16:32
szaby szaby is offline
Senior Member
 
Join Date: Jul 2008
Posts: 34
Default
I think this is a useless function. Why burden SQL with this?
Reply With Quote
  #3  
Old 13th October 2022, 13:26
BamBam0077 BamBam0077 is offline
Banned
 
Join Date: Jul 2013
P2P
Posts: 410
Default
because I use a private PHP VPN code developers code it maybe posted somewhere around here anyway so we could monitor our staffing team's
edit::!?/
SQL_Query_exec("UPDATE
update
sql_query("UPDATE
0R
mysqli_query("UPDATE

choice's I do tell you people is intended solely to assist and entertain PHP developers ;)
PHP.NET
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT +2. The time now is 10:01. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.