PageSourceSearch

https://eservices.fr/qa-plugin/q2apro-on-site-notifications/script.js

js eservices.fr collected 2026-10-06 18:27:06 UTC 2,166 bytes, 64 lines download raw bytes

1/*
2	Plugin Name: On-Site-Notifications
3	Plugin URI: http://www.q2apro.com/plugins/on-site-notifications
4	Plugin Description: Facebook-like / Stackoverflow-like notifications on your question2answer forum that can replace all email-notifications.
5	Plugin Version: 1.0
6	Plugin Date: 2014-03-29
7	Plugin Author: q2apro.com
8	Plugin Author URI: http://www.q2apro.com/
9	Plugin License: GPLv3
10	Plugin Minimum Question2Answer Version: 1.5
11	Plugin Update Check URI: https://raw.githubusercontent.com/q2apro/q2apro-on-site-notifications/master/qa-plugin.php
12	
13	This program is free software. You can redistribute and modify it 
14	under the terms of the GNU General Public License.
15
16	This program is distributed in the hope that it will be useful,
17	but WITHOUT ANY WARRANTY; without even the implied warranty of
18	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19	GNU General Public License for more details.
20
21	More about this license: http://www.gnu.org/licenses/gpl.html
22
23*/
24
25$(document).ready(function(){
26
27	$(document).on('click', '#nfyReadClose', function() {
28		$('#nfyWrap').fadeOut(500, function(){$(this).remove() });
29	});
30	$('.osn-new-events-link').click(function() {
31		// user clicked on N bubble again to hide event-box
32		if( $('#nfyWrap').length>0 && $('#nfyWrap').is(':visible') ) {
33			$('#nfyWrap').fadeOut(500, function(){$(this).remove() });
34		}
35		else {
36			var evrequest = 'receiveNotify';
37			$.ajax({
38				 type: 'POST',
39				 url: eventnotifyAjaxURL, // root
40				 data: {ajax:evrequest},
41				 cache: false,
42				 success: function(data) {
43					// remove Event-Box if formerly loaded
44					$('#nfyWrap').fadeOut(500, function(){$(this).remove() });
45					// insert ajax-loaded html 
46					// $('.qa-nav-user').append(data);
47					$('.osn-new-events-link').after(data);
48					// make yellow notification bubble gray
49					$('.ntfy-event-new').addClass('ntfy-read');
50				 }
51			});
52		}
53	});
54	
55	// fade out notifybox if visible on stage
56	$(document).click(function(event) { 
57		if($(event.target).parents().index($('#nfyWrap')) == -1) {
58			if($('#nfyWrap').is(':visible')) {
59				$('#nfyWrap').fadeOut(500, function(){$(this).remove() });
60			}
61		}        
62	})
63
64});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.