Skip to content

Commit b0af4fe

Browse files
committed
sync with hdxxxx pt site again;
use mysql again from mysqli(compatible with PHP5; compatible with product web site); update getip();update imdb.class.php;
1 parent 303af38 commit b0af4fe

File tree

125 files changed

+755
-794
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

125 files changed

+755
-794
lines changed

README

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,8 @@ for more detail: please contact me:
1414
20171130:
1515
mysql-->mysqli; update getip();update imdb.class.php;
1616
ignore config/allconfig.php, please restore it from config/allconfig.php.bak
17+
20171201:
18+
sync with hdxxxx pt site again;
19+
use mysql again from mysqli(compatible with PHP5; compatible with product web site);
20+
update getip();update imdb.class.php;
1721

RELEASENOTE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Release note for v1.5 beta 4 20100919
1515
Fix: "There is a minimum announce time of 30 seconds", caused by timezone settings. Now you should set correct timezone in php.ini
1616
Fix: varchar column length exceed 255 characters, which causes errors in MySQL 5.0.3 and later
1717
Mod: set mysql sql_mode in php level
18-
Mod: change mysql_pconnect to mysqli_connect
18+
Mod: change mysql_pconnect to mysql_connect
1919
Release note for v1.5 beta 4 20100905
2020
Add: promotion timeout setting per torrent
2121
Fix: some minor bugs

aboutnexus.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
end_frame();
2626
unset($ppl);
2727
$res = sql_query("SELECT * FROM language ORDER BY trans_state") or sqlerr();
28-
while ($arr = mysqli_fetch_assoc($res))
28+
while ($arr = mysql_fetch_assoc($res))
2929
{
3030
$ppl .= "<tr><td class=\"rowfollow\"><img width=\"24\" height=\"15\" src=\"pic/flag/".$arr[flagpic]."\" alt=\"".$arr[lang_name]."\" title=\"".$arr[lang_name]."\" style=\"padding-bottom:1px;\" /></td>
3131
<td class=\"rowfollow\">".$arr['lang_name']."</td>".
@@ -40,7 +40,7 @@
4040
end_frame();
4141
unset($ppl);
4242
$res = sql_query("SELECT * FROM stylesheets ORDER BY id") or sqlerr();
43-
while ($arr = mysqli_fetch_assoc($res))
43+
while ($arr = mysql_fetch_assoc($res))
4444
{
4545
$ppl .= "<tr><td class=\"rowfollow\">".$arr['name']."</td>
4646
<td class=\"rowfollow\">".$arr['designer']."</td>".

adduser.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@
2121
stderr("Error","Invalid username.");
2222
$username = sqlesc($username);
2323
$res = sql_query("SELECT id FROM users WHERE username=$username");
24-
$arr = sql_fetch_row($res);
24+
$arr = mysql_fetch_row($res);
2525
if ($arr)
2626
stderr("Error","Username already exists!");
2727
$password = $_POST["password"];
2828
$email = sqlesc($_POST["email"]);
2929
$res = sql_query("SELECT id FROM users WHERE email=$email");
30-
$arr = sql_fetch_row($res);
30+
$arr = mysql_fetch_row($res);
3131
if ($arr)
3232
stderr("Error","The e-mail address is already in use.");
3333
$secret = mksecret();
@@ -36,7 +36,7 @@
3636

3737
sql_query("INSERT INTO users (added, last_access, secret, username, passhash, status, stylesheet, class,email) VALUES(NOW(), NOW(), $secret, $username, $passhash, 'confirmed', ".$defcss.",".$defaultclass_class.",$email)") or sqlerr(__FILE__, __LINE__);
3838
$res = sql_query("SELECT id FROM users WHERE username=$username");
39-
$arr = sql_fetch_row($res);
39+
$arr = mysql_fetch_row($res);
4040
if (!$arr)
4141
stderr("Error", "Unable to create the account. The user name is possibly already taken.");
4242
header("Location: " . get_protocol_prefix() . "$BASEURL/userdetails.php?id=".htmlspecialchars($arr[0]));

admanage.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ function print_ad_editor($position, $row = "")
196196
stderr($lang_admanage['std_error'], $lang_admanage['std_invalid_id']);
197197
}
198198
$res = sql_query ("SELECT * FROM advertisements WHERE id = ".sqlesc($id)." LIMIT 1");
199-
if ($row = mysqli_fetch_array($res))
199+
if ($row = mysql_fetch_array($res))
200200
sql_query("DELETE FROM advertisements WHERE id = ".sqlesc($row['id'])) or sqlerr(__FILE__, __LINE__);
201201
$Cache->delete_value('current_ad_array', false);
202202
header("Location: ".get_protocol_prefix() . $BASEURL."/admanage.php");
@@ -212,7 +212,7 @@ function print_ad_editor($position, $row = "")
212212
else
213213
{
214214
$res = sql_query("SELECT * FROM advertisements WHERE id = ".sqlesc($id)." LIMIT 1");
215-
if (!$row = mysqli_fetch_array($res))
215+
if (!$row = mysql_fetch_array($res))
216216
stderr($lang_admanage['std_error'], $lang_admanage['std_invalid_id']);
217217
else
218218
{
@@ -261,14 +261,14 @@ function print_ad_editor($position, $row = "")
261261
{
262262
$adid = $id;
263263
$res = sql_query("SELECT * FROM advertisements WHERE id = ".sqlesc($id)." LIMIT 1");
264-
if (!$row = mysqli_fetch_array($res))
264+
if (!$row = mysql_fetch_array($res))
265265
stderr($lang_admanage['std_error'], $lang_admanage['std_invalid_id']);
266266
}
267267
}
268268
else
269269
{
270270
$res = sql_query("SELECT id FROM advertisements ORDER BY id DESC LIMIT 1");
271-
$row = mysqli_fetch_array($res);
271+
$row = mysql_fetch_array($res);
272272
if (!$row)
273273
$adid = 1;
274274
else $adid = $row['id']+1;
@@ -395,7 +395,7 @@ function print_ad_editor($position, $row = "")
395395
<td class="colhead"><?php echo $lang_admanage['col_action']?></td>
396396
</tr>
397397
<?php
398-
while ($row = mysqli_fetch_array($res))
398+
while ($row = mysql_fetch_array($res))
399399
{
400400
$clickcount=get_row_count("adclicks", "WHERE adid=".sqlesc($row['id']));
401401
?>

allagents.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
stdhead("All Clients");
99
print("<table align=center border=3 cellspacing=0 cellpadding=5>\n");
1010
print("<tr><td class=colhead>Client</td><td class=colhead>Peer ID</td></tr>\n");
11-
while($arr2 = mysqli_fetch_assoc($res2))
11+
while($arr2 = mysql_fetch_assoc($res2))
1212
{
1313
print("</a></td><td align=left>$arr2[agent]</td><td align=left>$arr2[peer_id]</td></tr>\n");
1414
}

allowedemails.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
stdhead ("Show List");
1414
print("<table border=1 cellspacing=0 cellpadding=5 width=737>\n");
1515
$sql = sql_query("SELECT * FROM allowedemails") or sqlerr(__FILE__, __LINE__);
16-
$list = mysqli_fetch_array($sql);
16+
$list = mysql_fetch_array($sql);
1717
?>
1818
<form method=post action=allowedemails.php>
1919
<input type=hidden name=action value=savelist>

amountbonus.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
sql_query("UPDATE users SET seedbonus=seedbonus + $seedbonus WHERE username=$username") or sqlerr(__FILE__, __LINE__);
2121
$res = sql_query("SELECT id FROM users WHERE username=$username");
22-
$arr = sql_fetch_row($res);
22+
$arr = mysql_fetch_row($res);
2323
if (!$arr)
2424
stderr("Error", "Unable to update account.");
2525
header("Location: " . get_protocol_prefix() . "$BASEURL/userdetails.php?id=".htmlspecialchars($arr[0]));

announce.php

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
// check passkey
5454
if (!$az = $Cache->get_value('user_passkey_'.$passkey.'_content')){
5555
$res = sql_query("SELECT id, downloadpos, enabled, uploaded, downloaded, class, parked, clientselect, showclienterror FROM users WHERE passkey=". sqlesc($passkey)." LIMIT 1");
56-
$az = mysqli_fetch_array($res);
56+
$az = mysql_fetch_array($res);
5757
$Cache->cache_value('user_passkey_'.$passkey.'_content', $az, 950);
5858
}
5959
if (!$az) err("Invalid passkey! Re-download the .torrent from $BASEURL");
@@ -82,7 +82,7 @@
8282
$torrentCacheKey = 'torrent_hash_'.bin2hex($info_hash).'_content';
8383
if (!$torrent = $Cache->get_value($torrentCacheKey)){
8484
$res = sql_query("SELECT id, owner, sp_state, seeders, leechers, UNIX_TIMESTAMP(added) AS ts, banned, hr, category FROM torrents WHERE " . hash_where("info_hash", $info_hash));
85-
$torrent = mysqli_fetch_array($res);
85+
$torrent = mysql_fetch_array($res);
8686
$Cache->cache_value($torrentCacheKey, $torrent, 350);
8787
}
8888
if (!$torrent){
@@ -124,7 +124,7 @@
124124
$peer_list = "";
125125
unset($self);
126126
// bencoding the peers info get for this announce
127-
while ($row = mysqli_fetch_assoc($res))
127+
while ($row = mysql_fetch_assoc($res))
128128
{
129129
$row["peer_id"] = hash_pad($row["peer_id"]);
130130

@@ -163,7 +163,7 @@
163163
if (!isset($self))
164164
{
165165
$res = sql_query("SELECT $fields FROM peers WHERE $selfwhere LIMIT 1");
166-
$row = mysqli_fetch_assoc($res);
166+
$row = mysql_fetch_assoc($res);
167167
if ($row)
168168
{
169169
$self = $row;
@@ -177,7 +177,7 @@
177177
// current peer_id, or you could say session with tracker not found in table peers
178178
if (!isset($self))
179179
{
180-
$valid = @sql_fetch_row(@sql_query("SELECT COUNT(*) FROM peers WHERE torrent=$torrentid AND userid=" . sqlesc($userid)));
180+
$valid = @mysql_fetch_row(@sql_query("SELECT COUNT(*) FROM peers WHERE torrent=$torrentid AND userid=" . sqlesc($userid)));
181181
if ($valid[0] >= 1 && $seeder == 'no') err("You already are downloading the same torrent. You may only leech from one location at a time.");
182182
if ($valid[0] >= 3 && $seeder == 'yes') err("You cannot seed the same torrent from more than 3 locations.");
183183

@@ -218,7 +218,7 @@
218218
if ($max > 0)
219219
{
220220
$res = sql_query("SELECT COUNT(*) AS num FROM peers WHERE userid='$userid' AND seeder='no'") or err("Tracker error 5");
221-
$row = mysqli_fetch_assoc($res);
221+
$row = mysql_fetch_assoc($res);
222222
if ($row['num'] >= $max) err("Your slot limit is reached! You may at most download $max torrents at the same time, please read $BASEURL/faq.php#id66 for details");
223223
}
224224
}
@@ -266,7 +266,7 @@
266266
if (isset($self) && $event == "stopped")
267267
{
268268
sql_query("DELETE FROM peers WHERE $selfwhere") or err("D Err");
269-
if (sql_affected_rows())
269+
if (mysql_affected_rows())
270270
{
271271
$updateset[] = ($self["seeder"] == "yes" ? "seeders = seeders - 1" : "leechers = leechers - 1");
272272
sql_query("UPDATE snatched SET uploaded = uploaded + $trueupthis, downloaded = downloaded + $truedownthis, to_go = $left, $announcetime, last_action = ".$dt." WHERE torrentid = $torrentid AND userid = $userid") or err("SL Err 1");
@@ -284,7 +284,7 @@
284284

285285
sql_query("UPDATE peers SET ip = ".sqlesc($ip).", port = $port, uploaded = $uploaded, downloaded = $downloaded, to_go = $left, prev_action = last_action, last_action = $dt, seeder = '$seeder', agent = ".sqlesc($agent)." $finished WHERE $selfwhere") or err("PL Err 1");
286286

287-
if (sql_affected_rows())
287+
if (mysql_affected_rows())
288288
{
289289
if ($seeder <> $self["seeder"])
290290
$updateset[] = ($seeder == "yes" ? "seeders = seeders + 1, leechers = leechers - 1" : "seeders = seeders - 1, leechers = leechers + 1");
@@ -309,11 +309,11 @@
309309
}
310310
sql_query("INSERT INTO peers (torrent, userid, peer_id, ip, port, connectable, uploaded, downloaded, to_go, started, last_action, seeder, agent, downloadoffset, uploadoffset, passkey) VALUES ($torrentid, $userid, ".sqlesc($peer_id).", ".sqlesc($ip).", $port, '$connectable', $uploaded, $downloaded, $left, $dt, $dt, '$seeder', ".sqlesc($agent).", $downloaded, $uploaded, ".sqlesc($passkey).")") or err("PL Err 2");
311311

312-
if (sql_affected_rows())
312+
if (mysql_affected_rows())
313313
{
314314
$updateset[] = ($seeder == "yes" ? "seeders = seeders + 1" : "leechers = leechers + 1");
315315

316-
$check = @sql_fetch_row(@sql_query("SELECT COUNT(*) FROM snatched WHERE torrentid = $torrentid AND userid = $userid"));
316+
$check = @mysql_fetch_row(@sql_query("SELECT COUNT(*) FROM snatched WHERE torrentid = $torrentid AND userid = $userid"));
317317
if (!$check['0']){
318318
$hr = $az['class'] < $bypass_userclass_hnr && $torrent['hr'] && is_require_hitrun(intval($torrent['ts'])) ? 1 : 0;
319319
sql_query("INSERT INTO snatched (torrentid, userid, ip, port, uploaded, downloaded, to_go, startdat, last_action, hr) VALUES ($torrentid, $userid, ".sqlesc($ip).", $port, $uploaded, $downloaded, $left, $dt, $dt, $hr)") or err("SL Err 4");

bannedemails.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
stdhead (VERSION." - Show List");
1212
print("<table border=1 cellspacing=0 cellpadding=5 width=737>\n");
1313
$sql = sql_query("SELECT * FROM bannedemails") or sqlerr(__FILE__, __LINE__);
14-
$list = mysqli_fetch_array($sql);
14+
$list = mysql_fetch_array($sql);
1515
?>
1616
<form method=post action=bannedemails.php>
1717
<input type=hidden name=action value=savelist>

bans.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
$remove = (int)$_GET['remove'];
99
if (is_valid_id($remove))
1010
{
11-
sql_query("DELETE FROM bans WHERE id=".sql_real_escape_string($remove)) or sqlerr();
11+
sql_query("DELETE FROM bans WHERE id=".mysql_real_escape_string($remove)) or sqlerr();
1212
write_log("Ban ".htmlspecialchars($remove)." was removed by $CURUSER[id] ($CURUSER[username])",'mod');
1313
}
1414

@@ -25,7 +25,7 @@
2525
stderr("Error", "Bad IP address.");
2626
$comment = sqlesc($comment);
2727
$added = sqlesc(date("Y-m-d H:i:s"));
28-
sql_query("INSERT INTO bans (added, addedby, first, last, comment) VALUES($added, ".sql_real_escape_string($CURUSER[id]).", $firstlong, $lastlong, $comment)") or sqlerr(__FILE__, __LINE__);
28+
sql_query("INSERT INTO bans (added, addedby, first, last, comment) VALUES($added, ".mysql_real_escape_string($CURUSER[id]).", $firstlong, $lastlong, $comment)") or sqlerr(__FILE__, __LINE__);
2929
header("Location: $_SERVER[REQUEST_URI]");
3030
die;
3131
}
@@ -38,15 +38,15 @@
3838

3939
print("<h1>Current Bans</h1>\n");
4040

41-
if (sql_num_rows($res) == 0)
41+
if (mysql_num_rows($res) == 0)
4242
print("<p align=center><b>Nothing found</b></p>\n");
4343
else
4444
{
4545
print("<table border=1 cellspacing=0 cellpadding=5>\n");
4646
print("<tr><td class=colhead>Added</td><td class=colhead align=left>First IP</td><td class=colhead align=left>Last IP</td>".
4747
"<td class=colhead align=left>By</td><td class=colhead align=left>Comment</td><td class=colhead>Remove</td></tr>\n");
4848

49-
while ($arr = mysqli_fetch_assoc($res))
49+
while ($arr = mysql_fetch_assoc($res))
5050
{
5151
print("<tr><td>".gettime($arr[added])."</td><td align=left>".long2ip($arr[first])."</td><td align=left>".long2ip($arr[last])."</td><td align=left>". get_username($arr['addedby']) .
5252
"</td><td align=left>$arr[comment]</td><td><a href=bans.php?remove=$arr[id]>Remove</a></td></tr>\n");

bitbucketlog.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,27 +10,27 @@
1010
{
1111
$delete = $_GET["delete"];
1212
if (is_valid_id($delete)) {
13-
$r = sql_query("SELECT name,owner FROM bitbucket WHERE id=".sql_real_escape_string($delete)) or sqlerr(__FILE__, __LINE__);
14-
if (sql_num_rows($r) == 1) {
15-
$a = mysqli_fetch_assoc($r);
13+
$r = sql_query("SELECT name,owner FROM bitbucket WHERE id=".mysql_real_escape_string($delete)) or sqlerr(__FILE__, __LINE__);
14+
if (mysql_num_rows($r) == 1) {
15+
$a = mysql_fetch_assoc($r);
1616
if (get_user_class() >= UC_MODERATOR || $a["owner"] == $CURUSER["id"]) {
17-
sql_query("DELETE FROM bitbucket WHERE id=".sql_real_escape_string($delete)) or sqlerr(__FILE__, __LINE__);
17+
sql_query("DELETE FROM bitbucket WHERE id=".mysql_real_escape_string($delete)) or sqlerr(__FILE__, __LINE__);
1818
if (!unlink("$bucketpath/$a[name]"))
1919
stderr("Warning", "Unable to unlink file: <b>$a[name]</b>. You should contact an administrator about this error.",false);
2020
} } } }
2121
stdhead("BitBucket Log");
22-
$res = sql_query("SELECT count(*) FROM bitbucket") or die(sql_error()); $row = mysqli_fetch_array($res); $count = $row[0];
22+
$res = sql_query("SELECT count(*) FROM bitbucket") or die(mysql_error()); $row = mysql_fetch_array($res); $count = $row[0];
2323
$perpage = 10;
2424
list($pagertop, $pagerbottom, $limit) = pager($perpage, $count, $_SERVER["PHP_SELF"] . "?out=" . $_GET["out"] . "&" );
2525
print("<h1>BitBucket Log</h1>\n");
2626
print("Total Images Stored: $count");
2727
echo $pagertop;
2828
$res = sql_query("SELECT * FROM bitbucket ORDER BY added DESC $limit") or sqlerr(__FILE__, __LINE__);
29-
if (sql_num_rows($res) == 0)
29+
if (mysql_num_rows($res) == 0)
3030
print("<b>BitBucket Log is empty</b>\n");
3131
else {
3232
print("<table align='center' border='0' cellspacing='0' cellpadding='5'>\n");
33-
while ($arr = mysqli_fetch_assoc($res)) {
33+
while ($arr = mysql_fetch_assoc($res)) {
3434
$date = substr($arr['added'], 0, strpos($arr['added'], " "));
3535
$time = substr($arr['added'], strpos($arr['added'], " ") + 1);
3636
$name = $arr["name"];

bookmark.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
if(isset($CURUSER))
1414
{
1515
$res_bookmark = sql_query("SELECT * FROM bookmarks WHERE torrentid=" . sqlesc($torrentid) . " AND userid=" . sqlesc($CURUSER[id]));
16-
if (sql_num_rows($res_bookmark) == 1){
16+
if (mysql_num_rows($res_bookmark) == 1){
1717
sql_query("DELETE FROM bookmarks WHERE torrentid=" . sqlesc($torrentid) . " AND userid=" . sqlesc($CURUSER['id'])) or sqlerr(__FILE__,__LINE__);
1818
$Cache->delete_value('user_'.$CURUSER['id'].'_bookmark_array');
1919
echo "deleted";

catmanage.php

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ function return_category_mode_selection($selname, $selectionid)
5353
{
5454
$res = sql_query("SELECT * FROM searchbox ORDER BY id ASC");
5555
$selection = "<select name=\"".$selname."\">";
56-
while ($row = mysqli_fetch_array($res))
56+
while ($row = mysql_fetch_array($res))
5757
$selection .= "<option value=\"" . $row["id"] . "\"". ($row["id"]==$selectedid ? " selected=\"selected\"" : "").">" . htmlspecialchars($row["name"]) . "</option>\n";
5858
$selection .= "</select>";
5959
return $selection;
@@ -160,7 +160,7 @@ function print_sub_category_list($type)
160160
<td class="colhead"><?php echo $lang_catmanage['col_action']?></td>
161161
</tr>
162162
<?php
163-
while ($row = mysqli_fetch_array($res))
163+
while ($row = mysql_fetch_array($res))
164164
{
165165
?>
166166
<tr>
@@ -401,7 +401,7 @@ function print_sub_category_editor($type, $row='')
401401
<td class="colhead"><?php echo $lang_catmanage['col_action']?></td>
402402
</tr>
403403
<?php
404-
while ($row = mysqli_fetch_array($res))
404+
while ($row = mysql_fetch_array($res))
405405
{
406406
?>
407407
<tr>
@@ -451,7 +451,7 @@ function print_sub_category_editor($type, $row='')
451451
<td class="colhead"><?php echo $lang_catmanage['col_action']?></td>
452452
</tr>
453453
<?php
454-
while ($row = mysqli_fetch_array($res))
454+
while ($row = mysql_fetch_array($res))
455455
{
456456
?>
457457
<tr>
@@ -500,7 +500,7 @@ function print_sub_category_editor($type, $row='')
500500
<td class="colhead"><?php echo $lang_catmanage['col_action']?></td>
501501
</tr>
502502
<?php
503-
while ($row = mysqli_fetch_array($res))
503+
while ($row = mysql_fetch_array($res))
504504
{
505505
?>
506506
<tr>
@@ -547,7 +547,7 @@ function print_sub_category_editor($type, $row='')
547547
<td class="colhead"><?php echo $lang_catmanage['col_action']?></td>
548548
</tr>
549549
<?php
550-
while ($row = mysqli_fetch_array($res))
550+
while ($row = mysql_fetch_array($res))
551551
{
552552
?>
553553
<tr>
@@ -582,7 +582,7 @@ function print_sub_category_editor($type, $row='')
582582
}
583583
$dbtablename=return_category_db_table_name($type);
584584
$res = sql_query ("SELECT * FROM ".$dbtablename." WHERE id = ".sqlesc($id)." LIMIT 1");
585-
if ($row = mysqli_fetch_array($res)){
585+
if ($row = mysql_fetch_array($res)){
586586
sql_query("DELETE FROM ".$dbtablename." WHERE id = ".sqlesc($row['id'])) or sqlerr(__FILE__, __LINE__);
587587
if(in_array($type, $validsubcattype))
588588
$Cache->delete_value($dbtablename.'_list');
@@ -611,7 +611,7 @@ function print_sub_category_editor($type, $row='')
611611
{
612612
$dbtablename=return_category_db_table_name($type);
613613
$res = sql_query ("SELECT * FROM ".$dbtablename." WHERE id = ".sqlesc($id)." LIMIT 1");
614-
if (!$row = mysqli_fetch_array($res))
614+
if (!$row = mysql_fetch_array($res))
615615
stderr($lang_catmanage['std_error'], $lang_catmanage['std_invalid_id']);
616616
else
617617
{
@@ -648,7 +648,7 @@ function print_sub_category_editor($type, $row='')
648648
else
649649
{
650650
$res = sql_query("SELECT * FROM ".$dbtablename." WHERE id = ".sqlesc($id)." LIMIT 1");
651-
if (!$row = mysqli_fetch_array($res))
651+
if (!$row = mysql_fetch_array($res))
652652
stderr($lang_catmanage['std_error'], $lang_catmanage['std_invalid_id']);
653653
}
654654
}
@@ -746,7 +746,7 @@ function print_sub_category_editor($type, $row='')
746746
$updateset[] = "audiocodec=".sqlesc($audiocodec);
747747
if($_POST['isedit']){
748748
$res2=sql_query("SELECT * FROM secondicons WHERE id=".sqlesc($id)." LIMIT 1");
749-
if ($row2=mysqli_fetch_array($res))
749+
if ($row2=mysql_fetch_array($res))
750750
{
751751
$Cache->delete_value('secondicon_'.$row2['source'].'_'.$row2['medium'].'_'.$row2['codec'].'_'.$row2['standard'].'_'.$row2['processing'].'_'.$row2['team'].'_'.$row2['audiocodec'].'_content');
752752
}

0 commit comments

Comments
 (0)