2009-12-07, 12:54 PM
Hello,
I am working on my advanced stats script right now, did something in the past which has to be improved to be released.
Right now it shows how many posts & threads have been written by how many users in the last X days, where X can be set bei the user (from 1-9999)
What I want to do right now ist to show how many posts have been written by the user who is online/asking right now. So there are no restrictions, he should just know how many posts he has written today.
This is, what I have:
Actually, this shows how many posts have been written in this amount of time, but how can I define, that just the UID X is counted?
I already put a " $UID = $mybb->user['uid'];" so I have the UID, does this help?
I hope, I make myself clear and somebody can help me!
thanks a lot,
regards,
FraGe
I am working on my advanced stats script right now, did something in the past which has to be improved to be released.
Right now it shows how many posts & threads have been written by how many users in the last X days, where X can be set bei the user (from 1-9999)
What I want to do right now ist to show how many posts have been written by the user who is online/asking right now. So there are no restrictions, he should just know how many posts he has written today.
This is, what I have:
// Get the number of posts by this user
$query = $db->simple_select("posts", "COUNT(uid) AS yourposts", "dateline > '$timecut'");
$yourposts = my_number_format($db->fetch_field($query, "yourposts"));
Actually, this shows how many posts have been written in this amount of time, but how can I define, that just the UID X is counted?
I already put a " $UID = $mybb->user['uid'];" so I have the UID, does this help?
I hope, I make myself clear and somebody can help me!
thanks a lot,
regards,
FraGe