2 <script language="javascript" type="text/javascript" src="$baseurl/library/tinymce/jscripts/tiny_mce/tiny_mce_src.js"></script>
3 <script language="javascript" type="text/javascript">
10 mode : "specific_textareas",
11 editor_selector: /(profile-jot-text|prvmail-text)/,
12 plugins : "bbcode,paste,fullscreen,autoresize",
13 theme_advanced_buttons1 : "bold,italic,underline,undo,redo,link,unlink,image,forecolor,formatselect,code,fullscreen",
14 theme_advanced_buttons2 : "",
15 theme_advanced_buttons3 : "",
16 theme_advanced_toolbar_location : "top",
17 theme_advanced_toolbar_align : "center",
18 theme_advanced_blockformats : "blockquote,code",
19 //theme_advanced_resizing : true,
20 //theme_advanced_statusbar_location : "bottom",
21 paste_text_sticky : true,
22 entity_encoding : "raw",
23 add_unload_trigger : false,
24 remove_linebreaks : false,
25 force_p_newlines : false,
26 force_br_newlines : true,
27 forced_root_block : '',
29 content_css: "$baseurl/view/custom_tinymce.css",
30 theme_advanced_path : false,
31 setup : function(ed) {
33 ed.onKeyUp.add(function(ed, e) {
34 var txt = tinyMCE.activeEditor.getContent();
36 if(textlen != 0 && $('#jot-perms-icon').is('.unlock')) {
37 $('#profile-jot-desc').html(ispublic);
40 $('#profile-jot-desc').html(' ');
44 $('#character-counter').removeClass('red');
45 $('#character-counter').removeClass('orange');
46 $('#character-counter').addClass('grey');
48 if((textlen > 140) && (textlen <= 420)) {
49 $('#character-counter').removeClass('grey');
50 $('#character-counter').removeClass('red');
51 $('#character-counter').addClass('orange');
54 $('#character-counter').removeClass('grey');
55 $('#character-counter').removeClass('orange');
56 $('#character-counter').addClass('red');
58 $('#character-counter').text(textlen);
61 ed.onInit.add(function(ed) {
62 ed.pasteAsPlainText = true;
69 <script type="text/javascript" src="include/ajaxupload.js" ></script>
71 var ispublic = '$ispublic';
72 $(document).ready(function() {
73 var uploader = new window.AjaxUpload(
75 { action: 'wall_upload/$nickname',
77 onSubmit: function(file,ext) { $('#profile-rotator').show(); },
78 onComplete: function(file,response) {
79 tinyMCE.execCommand('mceInsertRawHTML',false,response);
80 $('#profile-rotator').hide();
84 var file_uploader = new window.AjaxUpload(
86 { action: 'wall_attach/$nickname',
88 onSubmit: function(file,ext) { $('#profile-rotator').show(); },
89 onComplete: function(file,response) {
90 tinyMCE.execCommand('mceInsertRawHTML',false,response);
91 $('#profile-rotator').hide();
95 $('#contact_allow, #contact_deny, #group_allow, #group_deny').change(function() {
97 $('#contact_allow option:selected, #contact_deny option:selected, #group_allow option:selected, #group_deny option:selected').each( function() {
98 selstr = $(this).text();
99 $('#jot-perms-icon').removeClass('unlock').addClass('lock');
100 $('#jot-public').hide();
101 $('.profile-jot-net input').attr('disabled', 'disabled');
104 $('#jot-perms-icon').removeClass('lock').addClass('unlock');
105 $('#jot-public').show();
106 $('.profile-jot-net input').attr('disabled', false);
109 }).trigger('change');
113 function deleteCheckedItems() {
116 $('.item-select').each( function() {
117 if($(this).is(':checked')) {
118 if(checkedstr.length != 0) {
119 checkedstr = checkedstr + ',' + $(this).val();
122 checkedstr = $(this).val();
126 $.post('item', { dropitems: checkedstr }, function(data) {
127 window.location.reload();
131 function jotGetLink() {
132 reply = prompt("$linkurl");
133 if(reply && reply.length) {
134 reply = bin2hex(reply);
135 $('#profile-rotator').show();
136 $.get('parse_url?url=' + reply, function(data) {
137 tinyMCE.execCommand('mceInsertRawHTML',false,data);
138 $('#profile-rotator').hide();
143 function jotGetVideo() {
144 reply = prompt("$utubeurl");
145 if(reply && reply.length) {
146 tinyMCE.execCommand('mceInsertRawHTML',false,'[youtube]' + reply + '[/youtube]');
150 function jotVideoURL() {
151 reply = prompt("$vidurl");
152 if(reply && reply.length) {
153 tinyMCE.execCommand('mceInsertRawHTML',false,'[video]' + reply + '[/video]');
157 function jotAudioURL() {
158 reply = prompt("$audurl");
159 if(reply && reply.length) {
160 tinyMCE.execCommand('mceInsertRawHTML',false,'[audio]' + reply + '[/audio]');
165 function jotGetLocation() {
166 reply = prompt("$whereareu", $('#jot-location').val());
167 if(reply && reply.length) {
168 $('#jot-location').val(reply);
172 function jotTitle() {
173 reply = prompt("$title", $('#jot-title').val());
174 if(reply && reply.length) {
175 $('#jot-title').val(reply);
179 function jotShare(id) {
180 $('#like-rotator-' + id).show();
181 $.get('share/' + id, function(data) {
182 tinyMCE.execCommand('mceInsertRawHTML',false,data);
183 $('#like-rotator-' + id).hide();
184 $(window).scrollTop(0);
188 function linkdropper(event) {
189 var linkFound = event.dataTransfer.types.contains("text/uri-list");
191 event.preventDefault();
194 function linkdrop(event) {
195 var reply = event.dataTransfer.getData("text/uri-list");
196 event.target.textContent = reply;
197 event.preventDefault();
198 if(reply && reply.length) {
199 $('#profile-rotator').show();
200 $.get('parse_url?url=' + reply, function(data) {
201 tinyMCE.execCommand('mceInsertRawHTML',false,data);
202 $('#profile-rotator').hide();
207 function jotClearLocation() {
208 $('#jot-coord').val('');
209 $('#profile-nolocation-wrapper').hide();