diff options
author | friendica <redmatrix@redmatrix.me> | 2015-04-16 15:41:43 -0700 |
---|---|---|
committer | friendica <redmatrix@redmatrix.me> | 2015-04-16 15:41:43 -0700 |
commit | 507d04a98772ca73d9d1c1b4fb324159cff1d8ae (patch) | |
tree | c506762303a8f5940b3d443b6675a7a3c9fa8c68 /mod/webpages.php | |
parent | f09df061303f2f237865441a8d1dde133b33f5f2 (diff) | |
parent | 10cc643f650b5ff0954ff988fbf768ea5e061571 (diff) | |
download | volse-hubzilla-507d04a98772ca73d9d1c1b4fb324159cff1d8ae.tar.gz volse-hubzilla-507d04a98772ca73d9d1c1b4fb324159cff1d8ae.tar.bz2 volse-hubzilla-507d04a98772ca73d9d1c1b4fb324159cff1d8ae.zip |
Merge https://github.com/redmatrix/redmatrix into pending_merge
Diffstat (limited to 'mod/webpages.php')
-rw-r--r-- | mod/webpages.php | 27 |
1 files changed, 20 insertions, 7 deletions
diff --git a/mod/webpages.php b/mod/webpages.php index e2b5eb3a4..5013d803a 100644 --- a/mod/webpages.php +++ b/mod/webpages.php @@ -124,7 +124,7 @@ function webpages_content(&$a) { if($_REQUEST['pagetitle']) $x['pagetitle'] = $_REQUEST['pagetitle']; - $editor .= status_editor($a,$x); + $editor = status_editor($a,$x); // Get a list of webpages. We can't display all them because endless scroll makes that unusable, // so just list titles and an edit link. @@ -141,12 +141,24 @@ function webpages_content(&$a) { $pages = array(); foreach($r as $rr) { unobscure($rr); + $element_arr = array( + 'type' => 'webpage', + 'title' => $rr['title'], + 'body' => $rr['body'], + 'term' => $rr['term'], + 'created' => $rr['created'], + 'edited' => $rr['edited'], + 'mimetype' => $rr['mimetype'], + 'pagetitle' => $rr['sid'], + 'mid' => $rr['mid'] + ); $pages[$rr['iid']][] = array( - 'url' => $rr['iid'], - 'pagetitle' => $rr['sid'], - 'title' => $rr['title'], - 'created' => datetime_convert('UTC',date_default_timezone_get(),$rr['created']), - 'edited' => datetime_convert('UTC',date_default_timezone_get(),$rr['edited']) + 'url' => $rr['iid'], + 'pagetitle' => $rr['sid'], + 'title' => $rr['title'], + 'created' => datetime_convert('UTC',date_default_timezone_get(),$rr['created']), + 'edited' => datetime_convert('UTC',date_default_timezone_get(),$rr['edited']), + 'bb_element' => '[element]' . base64url_encode(json_encode($element_arr)) . '[/element]' ); } } @@ -158,8 +170,9 @@ function webpages_content(&$a) { $o .= replace_macros(get_markup_template('webpagelist.tpl'), array( '$listtitle' => t('Webpages'), '$baseurl' => $url, - '$create' => t('Create'), + '$create' => t('Create'), '$edit' => t('Edit'), + '$share' => t('Share'), '$delete' => t('Delete'), '$pages' => $pages, '$channel' => $which, |