]> git.mxchange.org Git - friendica.git/blobdiff - view/theme/frost-mobile/js/theme.js
Merge pull request #556 from fermionic/20121224-smarty3-template-collision
[friendica.git] / view / theme / frost-mobile / js / theme.js
index e9024cf5a3d80c9f6d3b35c2eb25806f893692ed..335a69536d6e27f472b701e01fba96016288faa6 100644 (file)
@@ -9,7 +9,7 @@ $j(document).ready(function() {
                        case 'jot-header':
                                var uploader = new window.AjaxUpload(
                                        'wall-image-upload',
-                                       { action: 'wall_upload/'+window.nickname,
+                                       { action: 'wall_upload/'+window.nickname+'?nomce=1',
                                                name: 'userfile',
                                                onSubmit: function(file,ext) { $j('#profile-rotator').show(); },
                                                onComplete: function(file,response) {
@@ -21,7 +21,7 @@ $j(document).ready(function() {
 
                                var file_uploader = new window.AjaxUpload(
                                        'wall-file-upload',
-                                       { action: 'wall_attach/'+window.nickname,
+                                       { action: 'wall_attach/'+window.nickname+'?nomce=1',
                                                name: 'userfile',
                                                onSubmit: function(file,ext) { $j('#profile-rotator').show(); },
                                                onComplete: function(file,response) {
@@ -34,7 +34,7 @@ $j(document).ready(function() {
                        case 'msg-header':
                                var uploader = new window.AjaxUpload(
                                        'prvmail-upload',
-                                       { action: 'wall_upload/' + window.nickname,
+                                       { action: 'wall_upload/'+window.nickname+'?nomce=1',
                                                name: 'userfile',
                                                onSubmit: function(file,ext) { $j('#profile-rotator').show(); },
                                                onComplete: function(file,response) {
@@ -49,7 +49,7 @@ $j(document).ready(function() {
                }
        }
 
-       if(typeof acl=="undefined"){
+       if(typeof window.aclInit !="undefined" && typeof acl=="undefined"){
                acl = new ACL(
                        baseurl+"/acl",
                        [ window.allowCID,window.allowGID,window.denyCID,window.denyGID ]
@@ -251,14 +251,14 @@ function insertFormatting(comment,BBcode,id) {
                textarea.focus();
                selected = document.selection.createRange();
                if (BBcode == "url"){
-                       selected.text = "["+BBcode+"]" + "http://" +  selected.text + "[/"+BBcode+"]";
+                       selected.text = "["+BBcode+"=http://]" +  selected.text + "[/"+BBcode+"]";
                        } else                  
                selected.text = "["+BBcode+"]" + selected.text + "[/"+BBcode+"]";
        } else if (textarea.selectionStart || textarea.selectionStart == "0") {
                var start = textarea.selectionStart;
                var end = textarea.selectionEnd;
                if (BBcode == "url"){
-                       textarea.value = textarea.value.substring(0, start) + "["+BBcode+"]" + "http://" + textarea.value.substring(start, end) + "[/"+BBcode+"]" + textarea.value.substring(end, textarea.value.length);
+                       textarea.value = textarea.value.substring(0, start) + "["+BBcode+"=http://]" + textarea.value.substring(start, end) + "[/"+BBcode+"]" + textarea.value.substring(end, textarea.value.length);
                        } else
                textarea.value = textarea.value.substring(0, start) + "["+BBcode+"]" + textarea.value.substring(start, end) + "[/"+BBcode+"]" + textarea.value.substring(end, textarea.value.length);
        }
@@ -533,17 +533,6 @@ function qCommentInsert(obj,id) {
        $j(obj).val("");
 }
 
-function showHideComments(id) {
-       if( $j("#collapsed-comments-" + id).is(":visible")) {
-               $j("#collapsed-comments-" + id).hide();
-               $j("#hide-comments-" + id).html(window.showMore);
-       }
-       else {
-               $j("#collapsed-comments-" + id).show();
-               $j("#hide-comments-" + id).html(window.showFewer);
-       }
-}
-
 /*function showHideCommentBox(id) {
        if( $j('#comment-edit-form-' + id).is(':visible')) {
                $j('#comment-edit-form-' + id).hide();