From 1cd3b4182595b838a535dd6b6990251db05d49e6 Mon Sep 17 00:00:00 2001 From: redmatrix Date: Wed, 30 Mar 2016 22:13:24 -0700 Subject: deprecate $a->get_baseurl() --- mod/editwebpage.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mod/editwebpage.php') diff --git a/mod/editwebpage.php b/mod/editwebpage.php index 0192fd9c0..f6cf22390 100644 --- a/mod/editwebpage.php +++ b/mod/editwebpage.php @@ -144,7 +144,7 @@ function editwebpage_content(&$a) { $layoutselect = layout_select($itm[0]['uid'],$itm[0]['layout_mid']); $a->page['htmlhead'] .= replace_macros(get_markup_template('jot-header.tpl'), array( - '$baseurl' => $a->get_baseurl(), + '$baseurl' => z_root(), '$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'), '$pretext' => '', '$ispublic' => ' ', // t('Visible to everybody'), @@ -192,7 +192,7 @@ function editwebpage_content(&$a) { '$ptyp' => $itm[0]['type'], '$content' => undo_post_tagging($itm[0]['body']), '$post_id' => $post_id, - '$baseurl' => $a->get_baseurl(), + '$baseurl' => z_root(), '$defloc' => $itm[0]['location'], '$visitor' => ($is_owner) ? true : false, '$acl' => populate_acl($itm[0],false), -- cgit v1.2.3 From 9abd95fad3784a10fc48bc40f9b8a75d7d74edda Mon Sep 17 00:00:00 2001 From: redmatrix Date: Thu, 31 Mar 2016 16:06:03 -0700 Subject: static App --- mod/editwebpage.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'mod/editwebpage.php') diff --git a/mod/editwebpage.php b/mod/editwebpage.php index f6cf22390..445c31ad4 100644 --- a/mod/editwebpage.php +++ b/mod/editwebpage.php @@ -8,7 +8,7 @@ function editwebpage_init(&$a) { if(argc() > 1 && argv(1) === 'sys' && is_site_admin()) { $sys = get_sys_channel(); if($sys && intval($sys['channel_id'])) { - $a->is_sys = true; + App::$is_sys = true; } } @@ -24,9 +24,9 @@ function editwebpage_init(&$a) { function editwebpage_content(&$a) { - if(! $a->profile) { + if(! App::$profile) { notice( t('Requested profile is not available.') . EOL ); - $a->error = 404; + App::$error = 404; return; } @@ -35,11 +35,11 @@ function editwebpage_content(&$a) { $uid = local_channel(); $owner = 0; $channel = null; - $observer = $a->get_observer(); + $observer = App::get_observer(); - $channel = $a->get_channel(); + $channel = App::get_channel(); - if($a->is_sys && is_site_admin()) { + if(App::$is_sys && is_site_admin()) { $sys = get_sys_channel(); if($sys && intval($sys['channel_id'])) { $uid = $owner = intval($sys['channel_id']); @@ -143,7 +143,7 @@ function editwebpage_content(&$a) { else $layoutselect = layout_select($itm[0]['uid'],$itm[0]['layout_mid']); - $a->page['htmlhead'] .= replace_macros(get_markup_template('jot-header.tpl'), array( + App::$page['htmlhead'] .= replace_macros(get_markup_template('jot-header.tpl'), array( '$baseurl' => z_root(), '$editselect' => (($plaintext) ? 'none' : '/(profile-jot-text|prvmail-text)/'), '$pretext' => '', @@ -211,7 +211,7 @@ function editwebpage_content(&$a) { '$profile_uid' => (intval($owner)), '$preview' => t('Preview'), '$jotplugins' => $jotplugins, - '$sourceapp' => $a->sourcename, + '$sourceapp' => App::$sourcename, '$defexpire' => '', '$feature_expire' => false, '$expires' => t('Set expiration date'), -- cgit v1.2.3 From e2b4d33627d5f4cf5f68eb087059d86c78eec41e Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Sat, 9 Apr 2016 12:16:42 +0200 Subject: some work on comanche autocomplete --- mod/editwebpage.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'mod/editwebpage.php') diff --git a/mod/editwebpage.php b/mod/editwebpage.php index 445c31ad4..9f6df9536 100644 --- a/mod/editwebpage.php +++ b/mod/editwebpage.php @@ -150,7 +150,8 @@ function editwebpage_content(&$a) { '$ispublic' => ' ', // t('Visible to everybody'), '$geotag' => $geotag, '$nickname' => $channel['channel_address'], - '$confirmdelete' => t('Delete webpage?') + '$confirmdelete' => t('Delete webpage?'), + '$bbco_autocomplete'=> 'bbcode', )); $tpl = get_markup_template("jot.tpl"); @@ -215,7 +216,7 @@ function editwebpage_content(&$a) { '$defexpire' => '', '$feature_expire' => false, '$expires' => t('Set expiration date'), - + '$bbco_autocomplete'=> 'bbcode' )); $o .= replace_macros(get_markup_template('edpost_head.tpl'), array( -- cgit v1.2.3 From b81291cd5c2d773c73d198fc97da31ecf16af880 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 13 Apr 2016 11:56:43 +0200 Subject: some bbcode autocomplete refinement for edit webpage --- mod/editwebpage.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mod/editwebpage.php') diff --git a/mod/editwebpage.php b/mod/editwebpage.php index 9f6df9536..7cf738989 100644 --- a/mod/editwebpage.php +++ b/mod/editwebpage.php @@ -151,7 +151,7 @@ function editwebpage_content(&$a) { '$geotag' => $geotag, '$nickname' => $channel['channel_address'], '$confirmdelete' => t('Delete webpage?'), - '$bbco_autocomplete'=> 'bbcode', + '$bbco_autocomplete'=> (($mimetype == 'text/bbcode') ? 'bbcode' : '') )); $tpl = get_markup_template("jot.tpl"); @@ -216,7 +216,7 @@ function editwebpage_content(&$a) { '$defexpire' => '', '$feature_expire' => false, '$expires' => t('Set expiration date'), - '$bbco_autocomplete'=> 'bbcode' + '$bbcode' => (($mimetype == 'text/bbcode') ? true : false) )); $o .= replace_macros(get_markup_template('edpost_head.tpl'), array( -- cgit v1.2.3