X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=mod%2Feditpost.php;h=1dc6aea21e054a3af159ebbda149cab5414a7538;hb=b75ca0d5b8c63ee86e97b4a32831fe03fe2b8fa3;hp=7a102119ba8a49caaa8ab4ace07bfd0a320ada10;hpb=229eb9c681d62edc5faa63bb1d66046d123c3f35;p=friendica.git
diff --git a/mod/editpost.php b/mod/editpost.php
index 7a102119ba..1dc6aea21e 100644
--- a/mod/editpost.php
+++ b/mod/editpost.php
@@ -18,29 +18,43 @@ function editpost_content(&$a) {
return;
}
- $r = q("SELECT * FROM `item` WHERE `id` = %d AND `uid` = %d LIMIT 1",
+ $itm = q("SELECT * FROM `item` WHERE `id` = %d AND `uid` = %d LIMIT 1",
intval($post_id),
intval(local_user())
);
- if(! count($r)) {
+ if(! count($itm)) {
notice( t('Item not found') . EOL);
return;
}
+ $plaintext = false;
+ if(local_user() && intval(get_pconfig(local_user(),'system','plaintext')))
+ $plaintext = true;
+
$o .= '
'
+ $jotnets .= '
'
. t("Post to Email") . '
';
}
@@ -76,36 +93,56 @@ function editpost_content(&$a) {
call_hooks('jot_tool', $jotplugins);
call_hooks('jot_networks', $jotnets);
- $tpl = replace_macros($tpl,array('$jotplugins' => $jotplugins));
+
+ //$tpl = replace_macros($tpl,array('$jotplugins' => $jotplugins));
+
$o .= replace_macros($tpl,array(
'$return_path' => $_SESSION['return_url'],
'$action' => 'item',
'$share' => t('Edit'),
'$upload' => t('Upload photo'),
+ '$shortupload' => t('upload photo'),
+ '$attach' => t('Attach file'),
+ '$shortattach' => t('attach file'),
'$weblink' => t('Insert web link'),
- '$youtube' => t('Insert YouTube video'),
- '$video' => t('Insert Vorbis [.ogg] video'),
- '$audio' => t('Insert Vorbis [.ogg] audio'),
+ '$shortweblink' => t('web link'),
+ '$video' => t('Insert video link'),
+ '$shortvideo' => t('video link'),
+ '$audio' => t('Insert audio link'),
+ '$shortaudio' => t('audio link'),
'$setloc' => t('Set your location'),
+ '$shortsetloc' => t('set location'),
'$noloc' => t('Clear browser location'),
+ '$shortnoloc' => t('clear location'),
'$wait' => t('Please wait'),
'$permset' => t('Permission settings'),
- '$content' => $r[0]['body'],
+ '$ptyp' => $itm[0]['type'],
+ '$content' => undo_post_tagging($itm[0]['body']),
'$post_id' => $post_id,
'$baseurl' => $a->get_baseurl(),
'$defloc' => $a->user['default-location'],
'$visitor' => 'none',
+ '$pvisit' => 'none',
'$emailcc' => t('CC: email addresses'),
+ '$public' => t('Public post'),
'$jotnets' => $jotnets,
+ '$title' => $itm[0]['title'],
+ '$placeholdertitle' => t('Set title'),
+ '$category' => file_tag_file_to_list($itm[0]['file'], 'category'),
+ '$placeholdercategory' => t('Categories (comma-separated list)'),
'$emtitle' => t('Example: bob@example.com, mary@example.com'),
'$lockstate' => $lockstate,
'$acl' => '', // populate_acl((($group) ? $group_acl : $a->user), $celeb),
'$bang' => (($group) ? '!' : ''),
- '$profile_uid' => $_SESSION['uid']
+ '$profile_uid' => $_SESSION['uid'],
+ '$preview' => t('Preview'),
+ '$jotplugins' => $jotplugins,
+ '$sourceapp' => t($a->sourcename),
+ '$cancel' => t('Cancel'),
+ '$rand_num' => random_digits(12)
));
-
return $o;
}