Help! What happens here in the last 24 hours

Started on the old forum in October 2009 · view the original in the archive · old links redirect here

10 replies · 617 views · started 17 years ago · 2 min read

4 participants
Leviathan73 Senior · 260 posts #1

Hello friends, I have this code in the file index.pgp, what happened in the last 24 hours

echo "<p>";
    //echo "<a href=\"index.php?action=124&sid=$sid\">»What happens here in the last 24 hours</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users"));
    echo "<a href=\"lists.php?action=members&sid=$sid\">»Members($norm[0])</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE sex='M'"));

and

else if($action=="l24")
{
  $mmsg = htmlspecialchars(getsetmood(getuid_sid($sid)));
    addonline(getuid_sid($sid),"Statistics ($mmsg)","");
    echo "<head>";
    echo "<title>Statistiche</title>";
    echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
    echo "</head>";
    echo "<body>";
    echo "<p>";
    /////
    echo "What happened to the $ sitename in the last 24 hours<br/><br/>";
    $tm24 = time() - (24*60*60);
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE lastact>'".$tm24."'"));
    echo "Members active: <b>$aut[0]</b><br/>";
$aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE regdate>'".$tm24."'"));
    echo "Members Registered: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_blogs WHERE bgdate>'".$tm24."'"));
    echo "Blogs Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE joined>'".$tm24."' AND accepted='1'"));
    echo "Members who have joined the Clubs: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubs WHERE created>'".$tm24."'"));
    echo "Clubs Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_buddies WHERE reqdt>'".$tm24."' AND agreed='1'"));
    echo "Friends Added: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_gbook WHERE dtime>'".$tm24."'"));
    echo "Guestbooks writings: <b>$aut[0]</b><br/>";
    if(ismod(getuid_sid($sid))){
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_mlog WHERE actdt>'".$tm24."'"));
    echo "ModLog Action: <b>$aut[0]</b><br/>";
  }
  $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_polls WHERE pdt>'".$tm24."'"));
    echo "Polls Added: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts WHERE dtpost>'".$tm24."'"));
    echo "Posts: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_private WHERE timesent>'".$tm24."'"));
    echo "PMs writing: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_shouts WHERE shtime>'".$tm24."'"));
    echo "Shouts: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE crdate>'".$tm24."'"));
    echo "Topics Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE pudt>'".$tm24."'"));
    echo "Vault (download) Added: <b>$aut[0]</b><br/>;";
    echo "</p>";
    echo "<p align=\"center\">";
echo "<b>5 </b><a accesskey=\"5\" href=\"index.php?action=stats&sid=$sid\">Statistics</a><br/>";
  echo "<br/><b>6 </b><a accesskey=\"6\" href=\"inbox.php?action=main&sid=$sid\">Inbox</a><br/>";

but in statistche unchecked, it is not seen. can you help me please?

srecnica Developer · 174 posts #2

This code works for me

else if($action=="l24") { addonline(getuid_sid($sid),"24h statistika HTML","index.php?action=$action");

$pstyle = gettheme($sid);
echo xhtmlhead("24 Hour Statistics",$pstyle);
echo "

"; echo ""; ///// echo "Sta se dogadjalo na HAPPY-ju za poslednja 24h

"; $tm24 = (time() - $timeadjust) - (246060) ; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_users WHERE lastact>'".$tm24."'")); echo "Aktivnih: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_users WHERE regdate>'".$tm24."'")); echo "Registrivanih: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_blogs WHERE bgdate>'".$tm24."'")); echo "Kreiranih blogova: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_clubmembers WHERE joined>'".$tm24."' AND accepted='1'")); echo "Uclanjenih u klubove: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_clubs WHERE created>'".$tm24."'")); echo "Kreiranih klubova: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_buddies WHERE reqdt>'".$tm24."' AND agreed='1'")); echo "Dodatih prijatelja: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_gbook WHERE dtime>'".$tm24."'")); echo "Upisa u GB: $aut[0] "; if(ismod(getuid_sid($sid))){ $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_mlog WHERE actdt>'".$tm24."'")); echo "ModCP Akcija: $aut[0] "; } $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_polls WHERE pdt>'".$tm24."'")); echo "Dodatih fotki: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_posts WHERE dtpost>'".$tm24."'")); echo "Postova: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_private WHERE timesent>'".$tm24."'")); echo "PP poruka: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_shouts WHERE shtime>'".$tm24."'")); echo "Razglasa: $aut[0] "; $aut = mysql_fetch_array(mysql_query("SELECT COUNT() FROM ibwf_topics WHERE crdate>'".$tm24."'")); echo "Kreiranih tema: $aut[0] "; echo " "; echo " "; echo "<a href="index.php?action=stats&sid=$sid"><img src="images/stat.gif" alt=""/>"; echo "Statistika</a> "; $thid = mysql_fetch_array(mysql_query("SELECT themeid FROM ibwf_users WHERE id='".$uid."'")); $themeimageset = mysql_fetch_array(mysql_query("SELECT themedir FROM ibwf_iconset WHERE id='".$thid[0]."'"));
echo "<img src="images/themes/$themeimageset[0]/home.gif" alt="*"/> <a href="index.php?action=main&sid=$sid">"; echo "HAPPY</a>"; echo " "; echo xhtmlfoot(); }

Translate to your language, but the features are the same

Leviathan73 Senior · 260 posts #3

but then your code there are different tables, does not go through the same! or if anyone has wapdesire laval, so you see my code

echo "<p>";
    //echo "<a href=\"index.php?action=124&sid=$sid\">»What happens here in the last 24 hours</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users"));
    echo "<a href=\"lists.php?action=members&sid=$sid\">»Members($norm[0])</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE sex='M'"));
Leviathan73 Senior · 260 posts #4

lacking the function in file list.php???

kazzin Junior · 33 posts #5
echo "<p>";
    echo "<a href=\"index.php?action=124&sid=$sid\">»What happens here in the last 24 hours</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users"));
    echo "<a href=\"lists.php?action=members&sid=$sid\">»Members($norm[0])</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE sex='M'"));

now add this juz copy n paste 😉

Leviathan73 Senior · 260 posts #6

you see, check this written What happens here in the last 24 hours

and when I click takes me out of the community, the home

kei_ki7 Senior · 431 posts #7

Leviathan73 wrote: Hello friends, I have this code in the file index.pgp, what happened in the last 24 hours

echo "<p>";
    //echo "<a href=\"index.php?action=124&sid=$sid\">»What happens here in the last 24 hours</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users"));
    echo "<a href=\"lists.php?action=members&sid=$sid\">»Members($norm[0])</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE sex='M'"));

and

else if($action=="l24")
{
  $mmsg = htmlspecialchars(getsetmood(getuid_sid($sid)));
    addonline(getuid_sid($sid),"Statistics ($mmsg)","");
    echo "<head>";
    echo "<title>Statistiche</title>";
    echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
    echo "</head>";
    echo "<body>";
    echo "<p>";
    /////
    echo "What happened to the $ sitename in the last 24 hours<br/><br/>";
    $tm24 = time() - (24*60*60);
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE lastact>'".$tm24."'"));
    echo "Members active: <b>$aut[0]</b><br/>";
$aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE regdate>'".$tm24."'"));
    echo "Members Registered: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_blogs WHERE bgdate>'".$tm24."'"));
    echo "Blogs Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE joined>'".$tm24."' AND accepted='1'"));
    echo "Members who have joined the Clubs: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubs WHERE created>'".$tm24."'"));
    echo "Clubs Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_buddies WHERE reqdt>'".$tm24."' AND agreed='1'"));
    echo "Friends Added: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_gbook WHERE dtime>'".$tm24."'"));
    echo "Guestbooks writings: <b>$aut[0]</b><br/>";
    if(ismod(getuid_sid($sid))){
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_mlog WHERE actdt>'".$tm24."'"));
    echo "ModLog Action: <b>$aut[0]</b><br/>";
  }
  $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_polls WHERE pdt>'".$tm24."'"));
    echo "Polls Added: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts WHERE dtpost>'".$tm24."'"));
    echo "Posts: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_private WHERE timesent>'".$tm24."'"));
    echo "PMs writing: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_shouts WHERE shtime>'".$tm24."'"));
    echo "Shouts: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE crdate>'".$tm24."'"));
    echo "Topics Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE pudt>'".$tm24."'"));
    echo "Vault (download) Added: <b>$aut[0]</b><br/>;";
    echo "</p>";
    echo "<p align=\"center\">";
echo "<b>5 </b><a accesskey=\"5\" href=\"index.php?action=stats&sid=$sid\">Statistics</a><br/>";
  echo "<br/><b>6 </b><a accesskey=\"6\" href=\"inbox.php?action=main&sid=$sid\">Inbox</a><br/>";

but in statistche unchecked, it is not seen. can you help me please?

..i think because of your wrong action .. try this

echo "<p>";
    echo "<a href=\"index.php?action=124&sid=$sid\">»What happens here in the last 24 hours</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users"));
    echo "<a href=\"lists.php?action=members&sid=$sid\">»Members($norm[0])</a><br/>";
    $norm = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE sex='M'"));

and

else if($action=="124")
{
  $mmsg = htmlspecialchars(getsetmood(getuid_sid($sid)));
    addonline(getuid_sid($sid),"Statistics ($mmsg)","");
    echo "<head>";
    echo "<title>Statistiche</title>";
    echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
    echo "</head>";
    echo "<body>";
    echo "<p>";
    /////
    echo "What happened to the $ sitename in the last 24 hours<br/><br/>";
    $tm24 = time() - (24*60*60);
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE lastact>'".$tm24."'"));
    echo "Members active: <b>$aut[0]</b><br/>";
$aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE regdate>'".$tm24."'"));
    echo "Members Registered: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_blogs WHERE bgdate>'".$tm24."'"));
    echo "Blogs Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE joined>'".$tm24."' AND accepted='1'"));
    echo "Members who have joined the Clubs: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubs WHERE created>'".$tm24."'"));
    echo "Clubs Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_buddies WHERE reqdt>'".$tm24."' AND agreed='1'"));
    echo "Friends Added: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_gbook WHERE dtime>'".$tm24."'"));
    echo "Guestbooks writings: <b>$aut[0]</b><br/>";
    if(ismod(getuid_sid($sid))){
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_mlog WHERE actdt>'".$tm24."'"));
    echo "ModLog Action: <b>$aut[0]</b><br/>";
  }
  $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_polls WHERE pdt>'".$tm24."'"));
    echo "Polls Added: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts WHERE dtpost>'".$tm24."'"));
    echo "Posts: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_private WHERE timesent>'".$tm24."'"));
    echo "PMs writing: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_shouts WHERE shtime>'".$tm24."'"));
    echo "Shouts: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE crdate>'".$tm24."'"));
    echo "Topics Created: <b>$aut[0]</b><br/>";
    $aut = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_vault WHERE pudt>'".$tm24."'"));
    echo "Vault (download) Added: <b>$aut[0]</b><br/>;";
    echo "</p>";
    echo "<p align=\"center\">";
echo "<b>5 </b><a accesskey=\"5\" href=\"index.php?action=stats&sid=$sid\">Statistics</a><br/>";
  echo "<br/><b>6 </b><a accesskey=\"6\" href=\"inbox.php?action=main&sid=$sid\">Inbox</a><br/>";

Did I help you? You can help me too Your donations will help me finance my studies.

kei_ki7 Senior · 431 posts #10

.. is problem solved already ??

.. thanks button is aLways there =)

Did I help you? You can help me too Your donations will help me finance my studies.

Write your reply now; next you create a free account (or sign in) and it is posted right away. Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close