To only work at certain times of the day?

Support area for phpBB's mChat extension
Ivan Petre Paul
Donor
Posts: 12
Joined: 30 Jul 2020, 13:31

To only work at certain times of the day?

Post by Ivan Petre Paul »

Hello everyone!
Is it possible for mChat to only work at certain times of the day? Kind of from 6pm to 10pm? And if we are out of range, an information message will be displayed, maybe even personalized.
User avatar
kasimi
mChat developer
Posts: 1108
Joined: 06 Oct 2016, 09:56
Location: Germany

Re: To only work at certain times of the day?

Post by kasimi »

Hi Ivan and welcome. :wave:

This is not possible with the current default mChat installation.

You could do it the manual way by only allowing mChat on the custom page and write a cron job that executes a simple script which sets the Enable mChat page setting according to your time range:

Code: Select all

UPDATE phpbb_config SET config_value=1/0 WHERE config_name = 'mchat_custom_page'
It is also possible to add this kind of feature to a standalone add-on extension, but this requires more work. Some details would need to be worked out, for example whose 6pm you mean. Server time? Local user time? Configurable? If you're interested in this solution, feel free to send me a PM and I'll let you know an estimate how much it would cost.
Ivan Petre Paul
Donor
Posts: 12
Joined: 30 Jul 2020, 13:31

Re: To only work at certain times of the day?

Post by Ivan Petre Paul »

Thank you, kasimi! I will think about it.

Who is online

Users browsing this forum: CCBot [Bot] and 0 guests