Changeset 15341 for extensions/lmt/admin
- Timestamp:
- May 27, 2012, 10:05:30 AM (12 years ago)
- Location:
- extensions/lmt/admin
- Files:
-
- 1 deleted
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/lmt/admin/plugin_admin_config.tpl
r6701 r15341 11 11 var objinput2 = new Array(); //input text from form => objinput[name] 12 12 var objhidden2 = new Array(); //input hidden from form => objhidden[name][lang] 13 var imgDir="{/literal}{$datas.img_directory}{literal}"; 13 14 14 15 {/literal} … … 16 17 {literal} 17 18 18 function change_logodefault()19 {20 if($("#ilicence_logo").val()=="text")21 {22 $("#logodefault").html(get_licence_text($("#ilicence_default").val(), true));23 }24 else25 {26 $("#logodefault").html("<img src='{/literal}{$datas.img_directory}{literal}"+27 $("#ilicence_default").val().toLowerCase()+"_"+28 $("#ilicence_logo").val()+".png'>");29 }30 change_example();31 }32 33 function init()34 {35 // initialize translations36 objlang = document.getElementById('islang');37 objlang2 = document.getElementById('iurlslang');38 39 for(i=0;i<objnames.length;i++)40 {41 objinput[i] = document.getElementById(objnames[i]);42 objhidden[i] = new Array();43 for(j=0;j<objlang.options.length;j++)44 {45 objhidden[i][j] = document.getElementById(objnames[i]+'_'+objlang.options[j].value);46 }47 }48 for(i=0;i<objnames2.length;i++)49 {50 objinput2[i] = document.getElementById(objnames2[i]);51 objhidden2[i] = new Array();52 for(j=0;j<objlang.options.length;j++)53 {54 objhidden2[i][j] = document.getElementById(objnames2[i]+'_'+objlang.options[j].value);55 }56 }57 58 //initialize help event59 $("sup").filter('.icnhelp').bind("mouseenter",60 function(event){61 $("#hinthlp").attr("innerHTML", get_hint(this))62 .css("left", event.clientX+1+window.pageXOffset)63 .css("top", event.clientY+1+window.pageYOffset);64 }65 );66 67 $("sup").filter('.icnhelp').bind("mouseleave",68 function(event){69 $("#hinthlp")70 .css("left", -450);71 }72 );73 74 }75 76 function change_lang()77 {78 for(i=0;i<objnames.length;i++)79 {80 objinput[i].value = objhidden[i][objlang.options.selectedIndex].value;81 }82 change_example();83 }84 85 function change_urllang()86 {87 for(i=0;i<objnames2.length;i++)88 {89 objinput2[i].value = objhidden2[i][objlang2.options.selectedIndex].value;90 }91 }92 93 94 function apply_changes(input_id)95 {96 var obj=document.getElementById(input_id);97 objhidden[objnames.indexOf(input_id)][objlang.options.selectedIndex].value = obj.value;98 99 change_example();100 }101 102 function apply_changes2(input_id)103 {104 var obj=document.getElementById(input_id);105 objhidden2[objnames2.indexOf(input_id)][objlang2.options.selectedIndex].value = obj.value;106 }107 108 function get_hint(obj)109 {110 switch(obj.id)111 {112 {/literal}113 {foreach from=$datas.help key=name item=txt}114 case '{$name}':return('{$txt}');115 break;116 {/foreach}117 {literal}118 }119 }120 121 function change_example()122 {123 var str = $("#itext").val();124 125 //var re = new RegExp('\\[logo=80x15\\]|\\[logo=88x31\\]|\\[logo=text\\]', "i");126 var re = new RegExp('\\[logo=80x15\\]', "i");127 img = "<img class='logo80x15' src='{/literal}{$datas.img_directory}{literal}"+$("#ilicence_default").val().toLowerCase()+"_80x15.png'>";128 str = str.replace(re, img);129 130 var re = new RegExp('\\[logo=88x31\\]', "i");131 img = "<img class='logo88x31' src='{/literal}{$datas.img_directory}{literal}"+$("#ilicence_default").val().toLowerCase()+"_88x31.png'>";132 str = str.replace(re, img);133 134 var re = new RegExp('\\[logo=text\\]', "i");135 txt = get_licence_text($("#ilicence_default").val(), false);136 str = str.replace(re, txt);137 138 $("#textexample").html(str);139 }140 19 141 20 </script> 142 21 {/literal} 143 144 <div id="hinthlp" class="hinthlp"></div>145 22 146 23 <form method="post" action="" class="general"> … … 151 28 <table class="formtable" > 152 29 <tr> 153 <td >{'lmt_cfg_licence_activated'|@translate}<sup id="hlp2" class="icnhelp">?</sup></td>30 <td class="icnhelp" title="{'lmt_help_config_2'|@translate}">{'lmt_cfg_licence_activated'|@translate}</td> 154 31 <td> 155 32 {html_options name="f_lmt_licence_activated" values=$lmt_yesno_values output=$lmt_yesno_labels selected=$datas.lmt_licence_activated} … … 161 38 162 39 <fieldset > 163 <legend>{'lmt_display_config'|@translate}</legend>164 <table class="formtable" >165 166 <tr>167 <td>{'lmt_cfg_list_maxheight'|@translate}<sup id="hlp1" class="icnhelp">?</sup></td>168 <td>169 <input type="text" name="f_lmt_list_maxheight" size="4"170 value="{$datas.lmt_list_maxheight}" maxlength="4" /> px171 </td>172 </tr>173 174 <tr>175 <td>{'lmt_cfg_list_maxitems'|@translate}<sup id="hlp9" class="icnhelp">?</sup></td>176 <td>177 <input type="text" name="f_lmt_list_maxitems" value="{$datas.lmt_list_maxitems}"178 maxlength="4" size="4" />179 </td>180 </tr>181 182 </table>183 </fieldset>184 185 <fieldset >186 40 <legend>{'lmt_licence_config'|@translate}</legend> 187 41 <table class="formtable" > 188 42 189 43 <tr> 190 <td >{'lmt_cfg_licence_visible'|@translate}<sup id="hlp3" class="icnhelp">?</sup></td>44 <td class="icnhelp" title="{'lmt_help_config_3'|@translate}">{'lmt_cfg_licence_visible'|@translate}</td> 191 45 <td> 192 46 {html_options name="f_lmt_licence_visible" values=$lmt_yesno_values output=$lmt_yesno_labels selected=$datas.lmt_licence_visible} … … 204 58 205 59 <tr> 206 <td >{'lmt_cfg_licence_default'|@translate}<sup id="hlp4" class="icnhelp">?</sup></td>60 <td class="icnhelp" title="{'lmt_help_config_4'|@translate}">{'lmt_cfg_licence_default'|@translate}</td> 207 61 <td> 208 62 <select name="f_lmt_licence_default" id="ilicence_default" onchange="change_logodefault();"> … … 213 67 214 68 <tr> 215 <td >{'lmt_cfg_licence_default_author'|@translate}<sup id="hlp8" class="icnhelp">?</sup></td>69 <td class="icnhelp" title="{'lmt_help_config_8'|@translate}">{'lmt_cfg_licence_default_author'|@translate}</td> 216 70 <td> 217 71 <select name="f_lmt_licence_default_author" id="ilicence_default_author"> … … 239 93 <table class="formtable" > 240 94 <tr> 241 <td >{'lmt_cfg_warning_visible'|@translate}<sup id="hlp5" class="icnhelp">?</sup></td>95 <td class="icnhelp" title="{'lmt_help_config_5'|@translate}">{'lmt_cfg_warning_visible'|@translate}</td> 242 96 <td> 243 97 {html_options name="f_lmt_warning_visible" values=$lmt_yesno_values output=$lmt_yesno_labels selected=$datas.lmt_warning_visible} … … 246 100 247 101 <tr> 248 <td >249 {'lmt_cfg_warning_texts'|@translate}< sup id="hlp7" class="icnhelp">?</sup><br/>102 <td class="icnhelp" title="{'lmt_help_config_7'|@translate}"> 103 {'lmt_cfg_warning_texts'|@translate}<br/> 250 104 <select onchange="change_lang();" id="islang"> 251 105 {html_options values=$lmt_language_list_values output=$lmt_language_list_labels selected=$lmt_language_selected} … … 261 115 <textarea id="itext" rows="4" cols="60" onkeyup="apply_changes('itext');" /></textarea> 262 116 </td> 263 </tr>264 265 <tr>266 <td> </td>267 <td style="font-size:90%;">{'lmt_warning_texts_help'|@translate}</td>268 117 </tr> 269 118 … … 288 137 289 138 <tr> 290 <td >{'lmt_cfg_warning_link'|@translate}<sup id="hlp6" class="icnhelp">?</sup></td>139 <td class="icnhelp" title="{'lmt_help_config_6'|@translate}">{'lmt_cfg_warning_link'|@translate}</td> 291 140 <td> 292 141 {html_options name="f_lmt_redirect_activated" values=$lmt_yesno_values output=$lmt_yesno_labels selected=$datas.lmt_redirect_activated} … … 295 144 296 145 <tr> 297 <td >{'lmt_cfg_warning_target'|@translate}<sup id="hlp10" class="icnhelp">?</sup></td>146 <td class="icnhelp" title="{'lmt_help_config_10'|@translate}">{'lmt_cfg_warning_target'|@translate}</td> 298 147 <td> 299 148 {html_options name="f_lmt_redirect_open_target" values=$lmt_yesno_values output=$lmt_yesno_labels selected=$datas.lmt_redirect_open_target} … … 332 181 </form> 333 182 334 <script type="text/javascript">335 change_logodefault();336 init();337 change_lang();338 change_urllang();339 </script> -
extensions/lmt/admin/plugin_admin_list.tpl
r7560 r15341 20 20 $("#nbphotos").html(msg.substr(0,msg.indexOf("#"))); 21 21 $("#list").html(msg.substr(msg.indexOf("#")+1)); 22 //$("#filter"). attr("innerHTML",msg.substr(msg.indexOf("#")+1));22 //$("#filter").html(msg.substr(msg.indexOf("#")+1)); 23 23 } 24 24 } -
extensions/lmt/admin/plugin_admin_manageaut.tpl
r10974 r15341 15 15 {/if} 16 16 {literal} 17 $("#iexample"). attr("innerHTML",txt);17 $("#iexample").html(txt); 18 18 } 19 19 ); … … 21 21 $("tr").filter(".TableRow_{/literal}{$themeconf.name}{literal}").bind("mouseout", 22 22 function (event) { 23 // $("#iexample"). attr("innerHTML","");23 // $("#iexample").html(""); 24 24 } 25 25 );
Note: See TracChangeset
for help on using the changeset viewer.