Inbox Limits Quota

Started on the old forum in September 2008 · view the original in the archive · old links redirect here

3 replies · 708 views · started 18 years ago · 1 min read

4 participants
sweetangel Lead · 885 posts #1

I wont add limit to inbox folder... max 50 inbox after users can deleted 4 continue use... how I can add this???

tnks 😉

if like my post click:

External image (may be gone)

looony Developer · 95 posts #2

what is the point of this

External image (may be gone)

if(isset($_SESSION['username'])) { print "everybody is a little loony inside"; } else { print"You should be shot"; }

djlee Developer · 224 posts #3

i dont use lavaliar or any other wap script for that matter but with the amount of posts you have im guessing your either incredibly thick and this post wont help .. or you know how to code and hopefully this will help

so break it down how you wanna do this ... the main question that pops up to me is how are you going to tell both users that inbox is full (both sending and receiving i mean) and do you want to store message until teh inbox is emptied to display them or just disable their messages til they clear um.

so lets say you simply want to disable inboxes when the users messages hit 50.

first you need to set this limit in the script that SENDS messages. before inserting the message into the database you need to query the database and get a count of how many messages a receiving user has.

$res = mysql_query("SELECT COUNT(*) FROM messages WHERE receiver = $id");
$arr = mysql_fetch_row($res);
if($arr[0] >= 50)
 {
  // Do Not send message and display error to user such as
  echo "This users inbox is full, please wait for them to clear their inbox before sending a message";
 }
else
 {
 // SEND MESSAGE CODE HERE (i.e. mysql query to insert into database)
 }

then in your header function you want to count teh number of message on each page load and if messages count > 50 for that user then display warning in box something like "your message limit has been reached. please delete some messages from yoru inbox or users cannot contact you"

basically its just a case of well placed IF statements to check message counts

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