From 75acc1ed966a6bb3e3ec690a667d148f900dba9c Mon Sep 17 00:00:00 2001 From: friendica Date: Fri, 17 Feb 2012 11:49:27 -0800 Subject: [PATCH] support plaintext on editpost, editorinit called before all buttons laid out --- mod/editpost.php | 4 ++++ view/jot-header.tpl | 2 +- view/jot.tpl | 5 ++--- view/theme/dispy/jot.tpl | 2 +- view/theme/duepuntozero/jot.tpl | 2 +- view/theme/loozah/jot.tpl | 2 +- view/theme/testbubble/jot.tpl | 2 +- 7 files changed, 11 insertions(+), 8 deletions(-) diff --git a/mod/editpost.php b/mod/editpost.php index f23b305f0e..778ac3dccd 100755 --- a/mod/editpost.php +++ b/mod/editpost.php @@ -28,6 +28,10 @@ function editpost_content(&$a) { return; } + $plaintext = false; + if(local_user() && intval(get_pconfig(local_user(),'system','plaintext'))) + $plaintext = true; + $o .= '

' . t('Edit post') . '

'; diff --git a/view/jot-header.tpl b/view/jot-header.tpl index 02662d2d4b..007f639b67 100755 --- a/view/jot-header.tpl +++ b/view/jot-header.tpl @@ -11,12 +11,12 @@ function initEditor(cb){ if(plaintext == 'none') { $("#profile-jot-text-loading").hide(); $("#profile-jot-text").css({ 'height': 200, 'color': '#000' }); - $(".jothidden").show(); editor = true; $("a#jot-perms-icon").fancybox({ 'transitionIn' : 'elastic', 'transitionOut' : 'elastic' }); + $(".jothidden").show(); if (typeof cb!="undefined") cb(); return; } diff --git a/view/jot.tpl b/view/jot.tpl index f116dc0f02..1c19dd6fac 100755 --- a/view/jot.tpl +++ b/view/jot.tpl @@ -13,9 +13,7 @@ - {{ if $content }}{{ endif }} - - +