23 lines
3.1 KiB
JavaScript
23 lines
3.1 KiB
JavaScript
/*
|
|
@licstart The following is the entire license notice for the JavaScript code in this page.
|
|
|
|
campagne d'adhésion pour l'association de Logiciels Libre "April"
|
|
|
|
Copyright (C) 2013 April
|
|
|
|
This program is free software: you can redistribute it and/or modify
|
|
it under the terms of the GNU Affero General Public License as
|
|
published by the Free Software Foundation, either version 3 of the
|
|
License, or (at your option) any later version.
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
GNU Affero General Public License for more details.
|
|
|
|
You should have received a copy of the GNU Affero General Public License
|
|
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
@licend The above is the entire license notice for the JavaScript code in this page.
|
|
*/
|
|
(function(){var t,e,n;jQuery(function(){return $("#radioAutreMontant").click(function(){return $("#autreMontant").focus()}),$("#autreMontant").focus(function(){return $("#radioAutreMontant").prop("checked",!0)}),$("#turingtest").val(Math.round(Date.now()/1e3)),e(),t(),$.localScroll(),$(window).scroll(function(){var t;return t=$(this).scrollTop()+20,$(".zone").each(function(){var e,r;return e=$(this),r=$("nav a."+e.attr("id")),null==e.data("x")&&n(),e.data("x")<=t&&t<=e.data("x_to")?r.addClass("active"):r.removeClass("active")})})}),n=function(){var t;return t=null,$(".zone").each(function(){var e;return e=$(this),e.data("x",e.position().top),null!=t&&t.data("x_to",e.position().top),t=e}),t.data("x_to",$(document).height())},e=function(){return $("#soutiens").load("wiki.html #bodyContent div > ul li *",function(){return $(this).children("a").each(function(){var t,e;return t=$(this),e=t.next(),e.attr("alt",t.html()),t.attr("title",t.html()).html(e),/twitter/.test(t.attr("href"))?t.attr("title"," -- "+t.attr("title")+" -- \n\nNous encourageons l'usage de Pump.io plutot que Twitter, privateur. \nPour en savoir plus \xe0 propos des probl\xe8mes pos\xe9s par Twitter selon la FSF, \nallez sur https://www.fsf.org/twitter"):void 0})})},jQuery.fn.extend({getUrlParam:function(t){var e,n,r,a,i;if(t=escape(unescape(t)),"#document"===$(this).attr("nodeName"))window.location.search.search(t)>-1&&(e=window.location.search.substr(1,window.location.search.length).split("&"));else if("undefined"!==$(this).attr("src"))a=$(this).attr("src"),a.indexOf("?")>-1&&(i=a.substr(a.indexOf("?")+1),e=i.split("&"));else{if("undefined"===$(this).attr("href"))return null;a=$(this).attr("href"),a.indexOf("?")>-1&&(i=a.substr(a.indexOf("?")+1),e=i.split("&"))}return e?(r=function(){var r,a,i;for(i=[],r=0,a=e.length;a>r;r++)n=e[r],escape(unescape(n.split("=")[0]))===t&&i.push(n.split("=")[1]);return i}(),0===r.lenght?null:1===r.lenght?r[0]:r):null}}),t=function(){var t;return t=$(document).getUrlParam("referent"),t?($("form #form_adhesion_motivations").val("Adh\xe9sion de soutien suite \xe0 la suggestion de "+t[0]),$("a").each(function(){var e;return e=$(this).attr("href"),e+=e.indexOf("?")>-1?"&":"?",$(this).attr("href",e+"referent="+t[0])})):void 0}}).call(this); |