Bravo List
Register
Go Back   > Bravo List > Source Code > Active Trackers > Torrent Trader > Mods & Themes
Reply
  #1  
Old 28th March 2013, 18:51
xlink xlink is offline
Member
 
Join Date: Mar 2013
P2P
Posts: 8
Default Error help please
Strict Standards: Only variables should be passed by reference in /home/www/viewtickets.php on line 28

Strict Standards: Only variables should be passed by reference in /home/www/viewtickets.php on line 29

Strict Standards: Only variables should be passed by reference in /home/www/viewtickets.php on line 30

Strict Standards: Only variables should be passed by reference in /home/www/viewtickets.php on line 31

Strict Standards: Only variables should be passed by reference in /home/www/viewtickets.php on line 32

Strict Standards: Only variables should be passed by reference in /home/www/viewtickets.php on line 33

PHP Code:
<?
require "backend/functions.php";
dbconn();

$res mysql_query("SELECT * FROM lottery_config") or sqlerr(__FILE____LINE__);
while (
$arr mysql_fetch_assoc($res))
$arr_config[$arr['name']] = $arr['value'];
$endday $arr_config['end_date'];
if (!
$arr_config["enable"])show_error_msg("Sorry""Lottery is disabled.");
stdhead();
begin_frame("Users who Have Purchased Tickets");
print(
"<center><font color=red>Lottery Ends: </font><b>" $endday "</b></center><br /><br />");
?>
<table align=center border="1" width="600" cellpadding="5">
<tr>
<td class="tabletitle">#</td>
<td class="tabletitle">User name</td>
<td class="tabletitle">Number of tickets</td>
<td class="tabletitle">Uploaded</td>
<td class="tabletitle">Downloaded</td>
<td class="tabletitle">Ratio</td>
</tr>
<?
$sql 
mysql_query("SELECT user FROM tickets") or die (mysql_error());
while (
$myrow mysql_fetch_assoc($sql))$user[] = $myrow["user"];
$user array_values(array_unique($user));
for (
$i 0$i sizeof($user); $i++){$tickets[] = mysql_num_rows(mysql_query("SELECT * FROM tickets WHERE user=$user[$i]"));
$username[] = end(mysql_fetch_row(mysql_query("SELECT username FROM users WHERE id=$user[$i]")));
$id[] = end(mysql_fetch_row(mysql_query("SELECT id FROM users WHERE id=$user[$i]")));
$uploaded[] = mksize(end(mysql_fetch_row(mysql_query("SELECT uploaded FROM users WHERE id=$user[$i]"))));
$downloaded[] = mksize(end(mysql_fetch_row(mysql_query("SELECT downloaded FROM users WHERE id=$user[$i]"))));
$ratio[] = end(mysql_fetch_row(mysql_query("SELECT downloaded FROM users WHERE id=$user[$i]")));
$ratio2[] = end(mysql_fetch_row(mysql_query("SELECT uploaded FROM users WHERE id=$user[$i]")));
echo 
"<tr><td class=tableb>" . ($i 1) . "</td>
<td class=tableb><a href=account-details.php?id=
$id[$i]>$username[$i]</a></td>
<td class=tableb>
$tickets[$i]</td>
<td class=tableb>
$uploaded[$i]</td>
<td class=tableb>
$downloaded[$i]</td>
<td class=tableb>" 
number_format($ratio2[$i] / $ratio[$i], 3) . "</td></tr>";
}
?>
</table>
<?
print("<center><h3><a href=games.php>Back to Casino</a></h3></center>");
end_frame();
stdfoot();
die;
?>
Reply With Quote
  #2  
Old 28th March 2013, 19:44
joeroberts's Avatar
joeroberts joeroberts is offline
BT.Manager Owner
 
Join Date: Jan 2008
United States
Posts: 2,113
Default
You are running way to many query's on that give this a shot
PHP Code:
 <?
require "backend/functions.php";
dbconn();

$res mysql_query("SELECT * FROM lottery_config") or sqlerr(__FILE____LINE__);
while (
$arr mysql_fetch_assoc($res))
$arr_config[$arr['name']] = $arr['value'];
$endday $arr_config['end_date'];
if (!
$arr_config["enable"])show_error_msg("Sorry""Lottery is disabled.");
stdhead();
begin_frame("Users who Have Purchased Tickets");
print(
"<center><font color=red>Lottery Ends: </font><b>" $endday "</b></center><br /><br />");
?>
<table align=center border="1" width="600" cellpadding="5">
<tr>
<td class="tabletitle">#</td>
<td class="tabletitle">User name</td>
<td class="tabletitle">Number of tickets</td>
<td class="tabletitle">Uploaded</td>
<td class="tabletitle">Downloaded</td>
<td class="tabletitle">Ratio</td>
</tr>
<?
$sql 
mysql_query("SELECT user FROM tickets") or die (mysql_error());
while (
$myrow mysql_fetch_assoc($sql))$user[] = $myrow["user"];
$user array_values(array_unique($user));
for (
$i 0$i sizeof($user); $i++){$tickets[] = mysql_num_rows(mysql_query("SELECT * FROM tickets WHERE user=$user[$i]"));
$sqy "SELECT username, uploaded, downloaded FROM users WHERE id=$user[$i]"
 
$vay mysql_query($sqy);
 
$sq mysql_fetch_row($vay);
$username[] = $sq['username'];
$id[] = $user[$i];
$uploaded[] = mksize($sq['uploaded']);
$downloaded[] = mksize($sq['downloaded']);
$ratio[] = $sq['downloaded'];
$ratio2[] = $sq['uploaded'];
echo 
"<tr><td class=tableb>" . ($i 1) . "</td>
<td class=tableb><a href=account-details.php?id=
$id[$i]>$username[$i]</a></td>
<td class=tableb>
$tickets[$i]</td>
<td class=tableb>
$uploaded[$i]</td>
<td class=tableb>
$downloaded[$i]</td>
<td class=tableb>" 
number_format($ratio2[$i] / $ratio[$i], 3) . "</td></tr>";
}
?>
</table>
<?
print("<center><h3><a href=games.php>Back to Casino</a></h3></center>");
end_frame();
stdfoot();
die;
?>
__________________
Do not ask me to help you work on your site that is not phpMyBitTorrent
Do not ask me to make a mod for any other source
Do not Ask me to setup your site.
I will no longer help you setup your site, there is a setup script if you have trouble with it post in the forum here or in BT.Manager™ forum
My Current Demo is here http://demo.btmanager.org/
Reply With Quote
  #3  
Old 28th March 2013, 20:00
xlink xlink is offline
Member
 
Join Date: Mar 2013
P2P
Posts: 8
Default
Parse error: syntax error, unexpected '$vay' (T_VARIABLE) in /home/www/viewtickets.php on line 29


Now the error has changed
Reply With Quote
  #4  
Old 28th March 2013, 20:01
joeroberts's Avatar
joeroberts joeroberts is offline
BT.Manager Owner
 
Join Date: Jan 2008
United States
Posts: 2,113
Default
sorry my fault
PHP Code:
 <?
require "backend/functions.php";
dbconn();

$res mysql_query("SELECT * FROM lottery_config") or sqlerr(__FILE____LINE__);
while (
$arr mysql_fetch_assoc($res))
$arr_config[$arr['name']] = $arr['value'];
$endday $arr_config['end_date'];
if (!
$arr_config["enable"])show_error_msg("Sorry""Lottery is disabled.");
stdhead();
begin_frame("Users who Have Purchased Tickets");
print(
"<center><font color=red>Lottery Ends: </font><b>" $endday "</b></center><br /><br />");
?>
<table align=center border="1" width="600" cellpadding="5">
<tr>
<td class="tabletitle">#</td>
<td class="tabletitle">User name</td>
<td class="tabletitle">Number of tickets</td>
<td class="tabletitle">Uploaded</td>
<td class="tabletitle">Downloaded</td>
<td class="tabletitle">Ratio</td>
</tr>
<?
$sql 
mysql_query("SELECT user FROM tickets") or die (mysql_error());
while (
$myrow mysql_fetch_assoc($sql))$user[] = $myrow["user"];
$user array_values(array_unique($user));
for (
$i 0$i sizeof($user); $i++){$tickets[] = mysql_num_rows(mysql_query("SELECT * FROM tickets WHERE user=$user[$i]"));
$sqy "SELECT username, uploaded, downloaded FROM users WHERE id=$user[$i]";
 
$vay mysql_query($sqy);
 
$sq mysql_fetch_row($vay);
$username[] = $sq['username'];
$id[] = $user[$i];
$uploaded[] = mksize($sq['uploaded']);
$downloaded[] = mksize($sq['downloaded']);
$ratio[] = $sq['downloaded'];
$ratio2[] = $sq['uploaded'];
echo 
"<tr><td class=tableb>" . ($i 1) . "</td>
<td class=tableb><a href=account-details.php?id=
$id[$i]>$username[$i]</a></td>
<td class=tableb>
$tickets[$i]</td>
<td class=tableb>
$uploaded[$i]</td>
<td class=tableb>
$downloaded[$i]</td>
<td class=tableb>" 
number_format($ratio2[$i] / $ratio[$i], 3) . "</td></tr>";
}
?>
</table>
<?
print("<center><h3><a href=games.php>Back to Casino</a></h3></center>");
end_frame();
stdfoot();
die;
?>
__________________
Do not ask me to help you work on your site that is not phpMyBitTorrent
Do not ask me to make a mod for any other source
Do not Ask me to setup your site.
I will no longer help you setup your site, there is a setup script if you have trouble with it post in the forum here or in BT.Manager™ forum
My Current Demo is here http://demo.btmanager.org/
Reply With Quote
  #5  
Old 28th March 2013, 20:12
xlink xlink is offline
Member
 
Join Date: Mar 2013
P2P
Posts: 8
Default
Click the image to open in full size.
Reply With Quote
  #6  
Old 28th March 2013, 20:22
joeroberts's Avatar
joeroberts joeroberts is offline
BT.Manager Owner
 
Join Date: Jan 2008
United States
Posts: 2,113
Default
PHP Code:
 <?
require "backend/functions.php";
dbconn();

$res mysql_query("SELECT * FROM lottery_config") or sqlerr(__FILE____LINE__);
while (
$arr mysql_fetch_assoc($res))
$arr_config[$arr['name']] = $arr['value'];
$endday $arr_config['end_date'];
if (!
$arr_config["enable"])show_error_msg("Sorry""Lottery is disabled.");
stdhead();
begin_frame("Users who Have Purchased Tickets");
print(
"<center><font color=red>Lottery Ends: </font><b>" $endday "</b></center><br /><br />");
?>
<table align=center border="1" width="600" cellpadding="5">
<tr>
<td class="tabletitle">#</td>
<td class="tabletitle">User name</td>
<td class="tabletitle">Number of tickets</td>
<td class="tabletitle">Uploaded</td>
<td class="tabletitle">Downloaded</td>
<td class="tabletitle">Ratio</td>
</tr>
<?
$sql 
mysql_query("SELECT user FROM tickets") or die (mysql_error());
while (
$myrow mysql_fetch_assoc($sql))$user[] = $myrow["user"];
$user array_values(array_unique($user));
for (
$i 0$i sizeof($user); $i++){
$tickets[] = mysql_num_rows(mysql_query("SELECT * FROM tickets WHERE user=$user[$i]"));
$sqy "SELECT id, username, uploaded, downloaded, uploaded/downloaded as user_ratio FROM users WHERE id=$user[$i]";
 
$vay mysql_query($sqy) or die (mysql_error());
 
$sq mysql_fetch_row($vay);
$username[] = $sq['username'];
$id[] = $sq['id'];
$uploaded[] = mksize($sq['uploaded']);
$downloaded[] = mksize($sq['downloaded']);
$ratio[] = $sq['user_ratio'];
$ratio2[] = $sq['uploaded'];
echo 
"<tr><td class=tableb>" . ($i 1) . "</td>
<td class=tableb><a href=account-details.php?id=
$id[$i]>$username[$i]</a></td>
<td class=tableb>
$tickets[$i]</td>
<td class=tableb>
$uploaded[$i]</td>
<td class=tableb>
$downloaded[$i]</td>
<td class=tableb>" 
number_format($ratio[$i], 3) . "</td></tr>";
}
?>
</table>
<?
print("<center><h3><a href=games.php>Back to Casino</a></h3></center>");
end_frame();
stdfoot();
die;
?>
__________________
Do not ask me to help you work on your site that is not phpMyBitTorrent
Do not ask me to make a mod for any other source
Do not Ask me to setup your site.
I will no longer help you setup your site, there is a setup script if you have trouble with it post in the forum here or in BT.Manager™ forum
My Current Demo is here http://demo.btmanager.org/
Reply With Quote
  #7  
Old 28th March 2013, 20:35
xlink xlink is offline
Member
 
Join Date: Mar 2013
P2P
Posts: 8
Default
Click the image to open in full size.


the only problem it does not show the values ​​only shows the quantity of tickets
Reply With Quote
  #8  
Old 28th March 2013, 20:44
joeroberts's Avatar
joeroberts joeroberts is offline
BT.Manager Owner
 
Join Date: Jan 2008
United States
Posts: 2,113
Default
PHP Code:
 <?
require "backend/functions.php";
dbconn();

$res mysql_query("SELECT * FROM lottery_config") or sqlerr(__FILE____LINE__);
while (
$arr mysql_fetch_assoc($res))
$arr_config[$arr['name']] = $arr['value'];
$endday $arr_config['end_date'];
if (!
$arr_config["enable"])show_error_msg("Sorry""Lottery is disabled.");
stdhead();
begin_frame("Users who Have Purchased Tickets");
print(
"<center><font color=red>Lottery Ends: </font><b>" $endday "</b></center><br /><br />");
?>
<table align=center border="1" width="600" cellpadding="5">
<tr>
<td class="tabletitle">#</td>
<td class="tabletitle">User name</td>
<td class="tabletitle">Number of tickets</td>
<td class="tabletitle">Uploaded</td>
<td class="tabletitle">Downloaded</td>
<td class="tabletitle">Ratio</td>
</tr>
<?
$sql 
mysql_query("SELECT user FROM tickets") or die (mysql_error());
while (
$myrow mysql_fetch_assoc($sql))$user[] = $myrow["user"];
$user array_values(array_unique($user));
for (
$i 0$i sizeof($user); $i++){
$tickets[] = mysql_num_rows(mysql_query("SELECT * FROM tickets WHERE user=$user[$i]"));
$sqy "SELECT id, username, uploaded, downloaded, uploaded/downloaded as user_ratio FROM users WHERE id=" $user[$i];
 
$vay mysql_query($sqy) or die (mysql_error());
 
$sq mysql_fetch_assoc($vay);
echo 
"<tr><td class=tableb>" . ($i 1) . "</td>
<td class=tableb><a href=account-details.php?id=" 
$sq['id'] . ">" $sq['username'] . "</a></td>
<td class=tableb>
$tickets[$i]</td>
<td class=tableb>" 
mksize($sq['uploaded']) . "</td>
<td class=tableb>" 
mksize($sq['downloaded']) . "</td>
<td class=tableb>" 
number_format($sq['user_ratio'], 3) . "</td></tr>";
}
?>
</table>
<?
print("<center><h3><a href=games.php>Back to Casino</a></h3></center>");
end_frame();
stdfoot();
die;
?>
__________________
Do not ask me to help you work on your site that is not phpMyBitTorrent
Do not ask me to make a mod for any other source
Do not Ask me to setup your site.
I will no longer help you setup your site, there is a setup script if you have trouble with it post in the forum here or in BT.Manager™ forum
My Current Demo is here http://demo.btmanager.org/
Reply With Quote
  #9  
Old 28th March 2013, 20:48
xlink xlink is offline
Member
 
Join Date: Mar 2013
P2P
Posts: 8
Default
ok now thanks
Reply With Quote
Reply

Tags
error

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 13:18. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.