2 $a->theme_info = array();
3 set_template_engine($a, 'smarty3');
5 function duepuntozero_init(&$a) {
6 $a->page['htmlhead'] .= <<< EOT
8 function insertFormatting(comment,BBcode,id) {
10 var tmpStr = $("#comment-edit-text-" + id).val();
11 if(tmpStr == comment) {
13 $("#comment-edit-text-" + id).addClass("comment-edit-text-full");
14 $("#comment-edit-text-" + id).removeClass("comment-edit-text-empty");
15 openMenu("comment-edit-submit-wrapper-" + id);
16 $("#comment-edit-text-" + id).val(tmpStr);
19 textarea = document.getElementById("comment-edit-text-" +id);
20 if (document.selection) {
22 selected = document.selection.createRange();
24 selected.text = "["+BBcode+"]" + "http://" + selected.text + "[/"+BBcode+"]";
26 selected.text = "["+BBcode+"]" + selected.text + "[/"+BBcode+"]";
27 } else if (textarea.selectionStart || textarea.selectionStart == "0") {
28 var start = textarea.selectionStart;
29 var end = textarea.selectionEnd;
31 textarea.value = textarea.value.substring(0, start) + "["+BBcode+"]" + "http://" + textarea.value.substring(start, end) + "[/"+BBcode+"]" + textarea.value.substring(end, textarea.value.length);
33 textarea.value = textarea.value.substring(0, start) + "["+BBcode+"]" + textarea.value.substring(start, end) + "[/"+BBcode+"]" + textarea.value.substring(end, textarea.value.length);
38 function cmtBbOpen(comment, id) {
39 if($(comment).hasClass('comment-edit-text-full')) {
40 $(".comment-edit-bb-" + id).show();
45 function cmtBbClose(comment, id) {
46 // if($(comment).hasClass('comment-edit-text-empty')) {
47 // $(".comment-edit-bb-" + id).hide();
52 $(document).ready(function() {
54 $('html').click(function() { $("#nav-notifications-menu" ).hide(); });
56 $('.group-edit-icon').hover(
58 $(this).addClass('icon'); $(this).removeClass('iconspacer');},
60 $(this).removeClass('icon'); $(this).addClass('iconspacer');}
63 $('.sidebar-group-element').hover(
65 id = $(this).attr('id');
66 $('#edit-' + id).addClass('icon'); $('#edit-' + id).removeClass('iconspacer');},
69 id = $(this).attr('id');
70 $('#edit-' + id).removeClass('icon');$('#edit-' + id).addClass('iconspacer');}
74 $('.savedsearchdrop').hover(
76 $(this).addClass('drop'); $(this).addClass('icon'); $(this).removeClass('iconspacer');},
78 $(this).removeClass('drop'); $(this).removeClass('icon'); $(this).addClass('iconspacer');}
81 $('.savedsearchterm').hover(
83 id = $(this).attr('id');
84 $('#drop-' + id).addClass('icon'); $('#drop-' + id).addClass('drophide'); $('#drop-' + id).removeClass('iconspacer');},
87 id = $(this).attr('id');
88 $('#drop-' + id).removeClass('icon');$('#drop-' + id).removeClass('drophide'); $('#drop-' + id).addClass('iconspacer');}