<?php
dbquery("UPDATE ".DB_PREFIX."users SET user_avatar = 'NULL' ");
?>
<?php
dbquery("UPDATE ".DB_USERS SET user_avatar = 'NULL' ");
?>
<?php
dbquery("UPDATE ".DB_USERS." SET user_avatar = 'NULL' ");
?>
Quote
Jay wrote:
it says table does not exist when i run that codeCode Download source<?php
dbquery("UPDATE ".DB_USERS." SET user_avatar = 'NULL' ");
?>
<?php
dbquery("UPDATE ".DB_PREFIX."users SET user_avatar = 'NULL' ");
?>
$result = dbquery(
"SELECT user_avatar,user_name,user_id FROM ".$db_prefix."users WHERE user_avatar OR user_id != '' ORDER BY RAND() LIMIT 1"
);
if (dbrows($result) == 1) {
@openside('Random Avatar');
$data=dbarray($result);
echo "<div style='text-align:center'>
<a href='".BASEDIR."profile.php?lookup=".$data['user_id']."' title='".$data['user_name']."'>\n";
if ($data['user_avatar']) {
echo "<img src='".BASEDIR."images/avatars/".$data['user_avatar']."' alt='".$data['user_name']."' border='0' width='100'>
<br>
".$data['user_name']."";
}
else {
echo "<img src='".BASEDIR."images/avatars/noimage.gif' alt='".$data['user_name']."' border='0'>
<br>
".$data['user_name']."
</a>
</div>";
@closeside();
}
}
<?php
$result = dbquery("SELECT user_avatar,user_name,user_id FROM ".$db_prefix."users WHERE user_avatar AND user_id != '' ORDER BY RAND() LIMIT 1");
if (dbrows($result) == 1) {
@openside('Random Avatar');
$data=dbarray($result);
echo "<div style='text-align:center'>
<a href='".BASEDIR."profile.php?lookup=".$data['user_id']."' title='".$data['user_name']."'>\n";
if ($data['user_avatar'] && file_exists(BASEDIR."images/avatars/".$data['user_avatar'])) {
echo "<img src='".BASEDIR."images/avatars/".$data['user_avatar']."' alt='".$data['user_name']."' border='0' width='100'>
<br>
".$data['user_name']."";
}
else {
echo "<img src='".BASEDIR."images/avatars/noimage.gif' alt='".$data['user_name']."' border='0'>
<br>
".$data['user_name']."
</a>
</div>";
@closeside();
}
}
?>
user_avatar
, in this format:filename[user_id].extension
my_avatar[19132].jpg
<?php
dbquery("UPDATE ".DB_PREFIX."users SET user_avatar = 'NULL' ");
?>
$result = dbquery(
"SELECT user_avatar,user_name,user_id FROM ".$db_prefix."users WHERE user_avatar OR user_id != '' ORDER BY RAND() LIMIT 1"
);
$result = dbquery(
"SELECT user_avatar,user_name,user_id FROM ".$db_prefix."users WHERE user_avatar != '' ORDER BY RAND() LIMIT 1"
);
if ($data['user_avatar']) {
if ($data['user_avatar'] && file_exists(BASEDIR."images/avatars/".$data['user_avatar'])) {
echo "<table width='100%'><tr><td>";
opentable('Random Avatar');
$result = dbquery(
"SELECT user_avatar,user_name,user_id FROM ".$db_prefix."users WHERE user_avatar != '' ORDER BY RAND() LIMIT 1"
);
if (dbrows($result) == 1) {
$data=dbarray($result);
echo "<div style='text-align:center'>
<a href='".BASEDIR."profile.php?lookup=".$data['user_id']."' title='".$data['user_name']."'>\n";
if ($data['user_avatar'] && file_exists(BASEDIR."images/avatars/".$data['user_avatar'])) {
echo "<img src='".BASEDIR."images/avatars/".$data['user_avatar']."' alt='".$data['user_name']."' border='0' width='100'>
<br>
".$data['user_name']."";
}
else {
echo "<img src='".BASEDIR."images/avatars/noimage.gif' alt='".$data['user_name']."' border='0'>
<br>
".$data['user_name']."
</a></div>";
}
}
closetable();
echo "</td></tr></table>";
Category Forum
Official Core Support - 6Labels
None yet
Statistics
0 participants
Notifications
You are not receiving notifications from this thread.
Related Questions