[Solved]Limit users to msgs allowed per hour

I want to restrict users to a limited number of messages per hour so that they dont choke the network.

has anyone tried this.?

see in Settings -> Main configuration -> Default settings tab -> Number of sent SMS per hour limit

but it will affect the server, not just users

anton

1 Like

Is there anyway to limit it per user ?

Have to implement. Today, the limit per hour is global, but, with smal modification, think be possible implement per user.

1 Like

Thank you in advance.
How can I do it?

Can you help me? Thanks

Anton, if you are reading this, correct me if I´m wrong, please.

In this function

function sendsms_throttle_isoverlimit($uid, $limit = 0, $period = 60)

there is $uid parameter, I think was thought to limit user sendings. But, only 0 is used as $uid. Maybe, if you change to real user id, it works. But, then, you have to create an additional field into user table, to save indivitual limits.

1 Like

I remember vaguely that the $uid was there for the purpose of limiting per user bases, but never got a chance to work on it, so its 0 to be used as global limit by everyone

anton

1 Like