PageSourceSearch

https://www.anonymus.qc.ca/wp-content/themes/anonymus/js/functions.inc.js

js anonymus.qc.ca collected 2026-10-03 00:20:12 UTC 5,181 bytes, 133 lines download raw bytes

1function chg1() {
2	var nom = document.getElementsByName("name")[0].value;
3	var texte = document.getElementById("texte1");
4	var chg1 = false;
5	if (nom == "")  
6	{
7		var bg = "/wp-content/themes/anonymus/images/notgood.gif";
8		chg1 = false;
9	} else {
10		var bg = "/wp-content/themes/anonymus/images/good.gif";
11		chg1 = true;
12	}
13	texte.style.backgroundImage="url("+bg+")";texte.style.backgroundPosition="right 0px";texte.style.backgroundRepeat="no-repeat";
14	return chg1;
15}
16function chg2() {
17	var mail = document.getElementsByName("email")[0].value;
18	var texte = document.getElementById("texte2");
19	var verif 	= /^[a-zA-Z0-9_.-]+@[a-zA-Z0-9-]{2,}[.][a-zA-Z.]{2,7}$/
20	var chg2 = false;
21	if (verif.exec(mail) == null)
22	{
23		var bg = "/wp-content/themes/anonymus/images/notgood.gif";
24		chg2 = false;
25	} else {
26		var bg = "/wp-content/themes/anonymus/images/good.gif";
27		chg2 = true;
28	}
29	texte.style.backgroundImage="url("+bg+")";texte.style.backgroundPosition="right 0px";texte.style.backgroundRepeat="no-repeat";
30	return chg2;
31}
32function chg3() {
33	var fnom = document.getElementsByName("fname")[0].value;
34	var texte = document.getElementById("texte3");
35	var chg3 = false;
36	if (fnom == "")  
37	{
38		var bg = "/wp-content/themes/anonymus/images/notgood.gif";
39		chg3 = false;
40	} else {
41		var bg = "/wp-content/themes/anonymus/images/good.gif";
42		chg3 = true;
43	}
44	texte.style.backgroundImage="url("+bg+")";texte.style.backgroundPosition="right 0px";texte.style.backgroundRepeat="no-repeat";
45	return chg3;
46}
47function chg4() {
48	var fmail = document.getElementsByName("femail")[0].value;
49	var texte = document.getElementById("texte4");
50	var chg4 = false;
51	var verif 	= /^[a-zA-Z0-9_.-]+@[a-zA-Z0-9-]{2,}[.][a-zA-Z.]{2,7}$/
52	if (verif.exec(fmail) == null)
53	{
54		var bg = "/wp-content/themes/anonymus/images/notgood.gif";
55		chg4 = false;
56	} else {
57		var bg = "/wp-content/themes/anonymus/images/good.gif";
58		chg4 = true;
59	}
60	texte.style.backgroundImage="url("+bg+")";texte.style.backgroundPosition="right 0px";texte.style.backgroundRepeat="no-repeat";
61	return chg4;
62}
63function CheckForm()
64{
65	var fmessage = document.getElementsByName("message")[0].value;
66	var msg_area = document.getElementById("MessageERROR");
67	msg_area.innerHTML = "";
68	if (fmessage.length > 255) {
69		msg_area.innerHTML = "Votre message ne peut dépacer 255 caractères!";
70	} else {
71	if (chg1() && chg2() && chg3() && chg4()) { document.formulaireToSendAFriend.submit(); }
72	}
73}	
74function showbm(divid)
75{
76	if ($("#"+divid).is(":hidden")) $("#"+divid).slideDown("slow"); 
77    else $("#"+divid).slideUp(); 
78	
79	return;
80}
81function get_full_text()
82{
83	if(!$("#txt").is(":hidden"))
84	{
85		$("#txt").hide();
86		$("#full_txt").css({top:0}).show();
87	}
88	else
89	{
90		$("#full_txt").hide();
91		$("#txt").css({top:0}).show();
92	}
93	return;
94}
95function goto(url)
96{
97	location.href = url;	
98}
99/*scrollto*/
100(function(h){var m=h.scrollTo=function(b,c,g){h(window).scrollTo(b,c,g)};m.defaults={axis:'y',duration:1};m.window=function(b){return h(window).scrollable()};h.fn.scrollable=function(){return this.map(function(){var b=this.parentWindow||this.defaultView,c=this.nodeName=='#document'?b.frameElement||b:this,g=c.contentDocument||(c.contentWindow||c).document,i=c.setInterval;return c.nodeName=='IFRAME'||i&&h.browser.safari?g.body:i?g.documentElement:this})};h.fn.scrollTo=function(r,j,a){if(typeof j=='object'){a=j;j=0}if(typeof a=='function')a={onAfter:a};a=h.extend({},m.defaults,a);j=j||a.speed||a.duration;a.queue=a.queue&&a.axis.length>1;if(a.queue)j/=2;a.offset=n(a.offset);a.over=n(a.over);return this.scrollable().each(function(){var k=this,o=h(k),d=r,l,e={},p=o.is('html,body');switch(typeof d){case'number':case'string':if(/^([+-]=)?\d+(px)?$/.test(d)){d=n(d);break}d=h(d,this);case'object':if(d.is||d.style)l=(d=h(d)).offset()}h.each(a.axis.split(''),function(b,c){var g=c=='x'?'Left':'Top',i=g.toLowerCase(),f='scroll'+g,s=k[f],t=c=='x'?'Width':'Height',v=t.toLowerCase();if(l){e[f]=l[i]+(p?0:s-o.offset()[i]);if(a.margin){e[f]-=parseInt(d.css('margin'+g))||0;e[f]-=parseInt(d.css('border'+g+'Width'))||0}e[f]+=a.offset[i]||0;if(a.over[i])e[f]+=d[v]()*a.over[i]}else e[f]=d[i];if(/^\d+$/.test(e[f]))e[f]=e[f]<=0?0:Math.min(e[f],u(t));if(!b&&a.queue){if(s!=e[f])q(a.onAfterFirst);delete e[f]}
100});q(a.onAfter);function q(b){o.animate(e,j,a.easing,b&&function(){b.call(this,r,a)})};function u(b){var c='scroll'+b,g=k.ownerDocument;return p?Math.max(g.documentElement[c],g.body[c]):k[c]}}).end()};function n(b){return typeof b=='object'?b:{top:b,left:b}}})(jQuery);
101function get_top()
102{
103	$.scrollTo( {top:"190px",left:0}, {duration:1000}  );
104	return;
105}
106$(document).ready(function() {
107	$("#simplePrint").click(function() {
108		window.print();
109	});
110});
111function printElem(options){
112     $('#toPrint').printElement(options);
113}
114function decompte()
115{
116	if(compte <= 1) {
117        pluriel = "";
118	} else {
119        pluriel = "s";
120    }
121		
122		document.getElementById("compt").innerHTML = compte + " seconde" + pluriel;
123 
124	if(compte == 0 || compte < 0) {
125        compte = 0;
126		/*location.reload();*/
127		/*window.location.href = "http://www.anonymus.qc.ca/telechargement";*/
128        document.frm.submit();
129		clearInterval(timer);
130    }
131    compte--;
132}
133

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.