New : Send Push notification directly from the topic page
Page 1 of 1
New : Send Push notification directly from the topic page
New : Send Push notification directly from the topic page |
Dear users, A very practical novelty has appeared on the Forumotion forums. Admins now have the ability to send push notifications directly from the discussion topic, without going through the Admin Panel. To do this, a new “Send Push Notification” icon is displayed next to the topic title (visible only to administrators). How does it work?As a reminder, a Push notification is a message consisting of a title, a text and an internal link to the forum which is sent to all visitors and/or members of your forum who have previously agreed to receive them. Until now, you could only send push notifications via the Administration Panel by filling out a small form dedicated to this operation (Admin Panel General Push Notifications - Write and send). Sending a push notification directly from the topic is much easier and faster. The title of the push, its text and its image are generated automatically, and you can send the push in 2 clicks. After clicking on icon of the bell , a confirmation pop-up opens asking you to validate the sending of the push. This pop-up window informs you at the same time about the number of push notifications left as part of your package.
Notifications sent in this way are counted and archived just like pushes sent via PA, in the following location:
All sendings must be spaced out by 5 minutes minimum, so it will be necessary to wait 5 minutes after the last push before sending a new one (moreover, apart from the last page consulted, the icons "Send Push Notification" will simply not be visible for 5 minutes). Also note that push notifications respect the topic visibility permissions. If the topic is visible to members and guests then the push will be sent to both. If it is visible only to members, the push will not be sent to guests. In addition, it is not possible to send pushes for a topic reserved for a group or for moderators.
The "Send Push Notification" icon is not displayed, why?You have certainly already understood that sending pushes is only possible if certain conditions are met. The bell icon will be visible only if the condition set is present. If you don't see this icon next to the topic title, and can't find the reason right away, here is a little checklist, to check the necessary conditions.
Also, the very first time it may be necessary to clear the CSS cache. To do this, simply go to the PA > Display > Colors and just click on the "Save" button, without any modification.
|
A Forumotion Important Announcement |
skouliki, Ape, SLGray, Niko, SarkZKalie, Terminator44 and hoanglongnhatbao like this post
Re: New : Send Push notification directly from the topic page
| Administrators who have customized the templates viewtopic_body and viewcomments_body should consider the changes below. (Administrators who have not customized this template are not affected by these changes included natively in the basic template of the forum.) |
| As a reminder, the viewcomments_body template is only visible if you have activated Blog mode in PA Modules Blogs Configuration |
First part (all versions)
In all versions, add this block of code in 2 templates at the beginning or at the end of the template:
- viewtopic_body
- viewcomments_body
- ADD:
- Add this code in 2 templates:
- Code:
<!-- BEGIN switch_push_direct_send -->
<div id="push-answer" class="jqmWindow"></div>
<script src="{JQUERY_DIR}jqmodal/jqmodal.js" type="text/javascript"></script>
<script>
//<![CDATA[
$(document).ready(function() {
$('#push-answer').jqm({toTop: true});
$('#push-bell').click(function () {
return sendWebPush({TOPIC_ID});
});
function sendWebPush(tId) {
$.get("/ajax_push.php?topicID=" + tId).done(showPushAnswer);
}
function showPushAnswer(data) {
$('#push-answer').html(data).jqmShow();
$('.jqmOverlay').bgiframe();
$('#push-answer').bgiframe();
}
});
//]]>
</script>
<!-- END switch_push_direct_send -->
Second part (depending on the version)
PhpBB2
- viewcomments_body:
Replace:- Code:
<td align="center" nowrap="nowrap" class="t-title"><h1 class="cattitle"> {TOPIC_TITLE}</h1></td>
With:- Code:
<td align="center" nowrap="nowrap" class="t-title"><h1 class="cattitle"> {TOPIC_TITLE}<!-- BEGIN switch_push_direct_send --> <span id="push-bell" title="{switch_push_direct_send.L_PUSH_SEND}"></span><!-- END switch_push_direct_send --></h1></td>
- viewtopic_body:
Replace:- Code:
<h1 class="cattitle"> {TOPIC_TITLE}</h1>
With:- Code:
<h1 class="cattitle"> {TOPIC_TITLE}<!-- BEGIN switch_push_direct_send --> <span id="push-bell" title="{switch_push_direct_send.L_PUSH_SEND}"></span><!-- END switch_push_direct_send --></h1>
PhpBB3
- viewcomments_body:
Replace:- Code:
<h1 class="page-title"><a href="{TOPIC_URL}">{TOPIC_TITLE}</a></h1>
With:- Code:
<h1 class="page-title">
<a href="{TOPIC_URL}">{TOPIC_TITLE}</a>
<!-- BEGIN switch_push_direct_send --> <span id="push-bell" title="{switch_push_direct_send.L_PUSH_SEND}"></span><!-- END switch_push_direct_send -->
</h1>
- viewtopic_body:
Add:- Code:
<!-- BEGIN switch_push_direct_send --> <span id="push-bell" title="{switch_push_direct_send.L_PUSH_SEND}"></span><!-- END switch_push_direct_send -->
After:- Code:
<a href="{TOPIC_URL}">{TOPIC_TITLE}</a>
PunBB and Invision
- viewcomments_body and viewtopic_body:
Replace:- Code:
<h1>{TOPIC_TITLE}</h1>
With:- Code:
<h1>{TOPIC_TITLE}<!-- BEGIN switch_push_direct_send --> <span id="push-bell" title="{switch_push_direct_send.L_PUSH_SEND}"></span><!-- END switch_push_direct_send --></h1>
ModernBB
- viewcomments_body and viewtopic_body:
Add:- Code:
<!-- BEGIN switch_push_direct_send --> <span id="push-bell" style="color:goldenrod;" title="{switch_push_direct_send.L_PUSH_SEND}" class="ion-android-notifications"></span><!-- END switch_push_direct_send -->
After:- Code:
<a href="{TOPIC_URL}">{TOPIC_TITLE}</a>
AwesomeBB
- viewcomments_body and viewtopic_body:
Replace:- Code:
<h1><a href="{TOPIC_URL}">{TOPIC_TITLE}</a></h1>
With:- Code:
<h1><a href="{TOPIC_URL}">{TOPIC_TITLE}</a><!-- BEGIN switch_push_direct_send --> <span id="push-bell" style="color:goldenrod;" title="{switch_push_direct_send.L_PUSH_SEND}"><i class="material-icons">notifications</i></span><!-- END switch_push_direct_send --></h1>
SLGray, Niko and hoanglongnhatbao like this post
Similar topics
» Add time of the notification directly in the toolbar
» Unable To Edit Directly From Members Profile Page.
» When I mention someone, it doesn't send the notification.
» HTML Page Form Send Issue
» Cannot send private message from Profile Page.
» Unable To Edit Directly From Members Profile Page.
» When I mention someone, it doesn't send the notification.
» HTML Page Form Send Issue
» Cannot send private message from Profile Page.
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum