vBulletin Mods

The Official vBulletin Modifications Site
https://www.vbulletin.org/forum/showthread.php?t=326558

Web Push notifications using OneSignal
by iA1
11 Jul 2018 14:36

4 Attachment(s)
Description:

OneSignal has an API that allows us to send unlimited web and push notifications for FREE. When I came to know about it, I spent several days and months searching for compatible plugins for vB4. Finally decided to learn and create my own based on pierce's similar mod for Xenforo.

Push notifications is a great way to keep your members engaged. It keeps driving them back to your site. This mod works great on mobile browsers as well.

This is the lite version which allows you to send web push notifications to your users whenever:
  1. someone replies on their subscribed threads
  2. sends them a PM
  3. likes one of their posts (dbtech thanks)

Installation:
  1. Register an account at OneSignal.com
  2. Download attached zip file. Upload the file functions_OneSignal.php under /includes directory
  3. Install the product using the xml file
  4. Go back to onesignal.com, under settings, click on Keys & IDs.
    https://www.vbulletin.org/forum/external/2018/07/7.png
  5. Copy these keys and paste them in the settings in admincp.
    https://www.vbulletin.org/forum/external/2018/07/8.png


Disclaimer:
I am not associated with onesignal in any way. This is just something that I found useful for my forum and wanted to share with everyone else.

If I get enough support then I plan to add notifications for moderators' actions and for quotes and tags as well.


Download latest version: 1.3.5
If upgrading from previous version, replace the functions file as well.

Change log:
1.3.5 - Typo fixed
1.3.0 - Separated multiple consecutive notifications for different threads
1.2.0 - Added privacy for replies in private sections and
Subscribe button at the end of posts
1.1.0 - Fixed issue with sub-forum
1.0.1 - Fixed Table Prefix bug
1.0.0 - Initial Release

iA1 11 Jul 2018 14:39

Screenshots:


scottkoz20 11 Jul 2018 17:46

This looks extremely interesting

iA1 11 Jul 2018 19:09

Quote:

Originally Posted by scottkoz20 (Post 2595494)
This looks extremely interesting

Glad you liked it. Screenshots are added in the above post.

scottkoz20 11 Jul 2018 19:54

something that I noticed is that the server load spikes when this is active - testing more

iA1 11 Jul 2018 19:58

Quote:

Originally Posted by scottkoz20 (Post 2595498)
something that I noticed is that the server load spikes when this is active - testing more

How big is your forum and how many users are active simultaneously?

IggyP 12 Jul 2018 16:14

looking forward to testing this, not sure when i will be able to, but the other mod like this i tried had some fatal conflicts somewhere with other mods or whatever i was using.

scottkoz20 14 Jul 2018 00:11

Quote:

Originally Posted by scottkoz20 (Post 2595498)
something that I noticed is that the server load spikes when this is active - testing more

i can't say with certainty that my load spike is your mod. I'll watch it though

carik 15 Sep 2018 14:41

Good afternoon.
I installed the mod, did everything according to the instructions, notifications come only from the themes of one forum, from other forums it comes only to e-mail. What could be the problem? Thank you!

carik 15 Sep 2018 15:08

sends notifications only from the topic, in English. Of those in the Russian language does not send. How to solve a problem? Thank you!

carik 15 Sep 2018 15:26

Even if the topic name in English, and the text of the response in Russian, the notification is not sent.

iA1 15 Sep 2018 19:54

Quote:

Originally Posted by carik (Post 2596364)
sends notifications only from the topic, in English. Of those in the Russian language does not send. How to solve a problem? Thank you!

I am not sure why it doesn't work for Russian. Can you check your OneSignal control panel for message logs and see if there is any error listed there?

I have tested this with another language and it worked fine for me without any issues.

carik 15 Sep 2018 20:03

Quote:

Originally Posted by iA1 (Post 2596366)
I am not sure why it doesn't work for Russian. Can you check your OneSignal control panel for message logs and see if there is any error listed there?

I have tested this with another language and it worked fine for me without any issues.

thanks for the answer.
if I send test messages from the OneSign panel, there are no errors. When I create a topic on the forum, the name in English, I write in it in English, there are no problems, push message comes. I think that the error with the processing of php mod ... or the encoding does not understand. I do not see any errors in the logs. And I tried to translate phrases in a php file, for example, "replied to", immediately ceases to send push messages.

carik 15 Sep 2018 20:25

and perhaps when sending push to convert the encoding cp1251 to utf-8? I see that the problem is this. Thank you.

carik 17 Sep 2018 15:22

Quote:

Originally Posted by iA1 (Post 2596366)
I am not sure why it doesn't work for Russian. Can you check your OneSignal control panel for message logs and see if there is any error listed there?

I have tested this with another language and it worked fine for me without any issues.

And can I make it so that a notification without nicknames, topic names and messages is sent? The usual notification is a "new answer", or "a new personal message". And click on the link to send a link to a topic or personal message.
That would be the right decision! Moreover, I have a very small notice on the 27 "screen, and it's easier for me to click and read on the site." It's also more convenient for me to follow the link on a mobile phone.


All times are GMT. The time now is 18:23.

Powered by vBulletin® Version 3.8.14
Copyright © 2020, MH Sub I, LLC dba vBulletin. All Rights Reserved. vBulletin® is a registered trademark of MH Sub I, LLC
Copyright ©2001 - , vbulletin.org. All rights reserved.