aboutsummaryrefslogtreecommitdiffstats
path: root/mod/webpages.php
diff options
context:
space:
mode:
authorPaolo T <tuscanhobbit@users.noreply.github.com>2013-10-11 00:24:25 -0700
committerPaolo T <tuscanhobbit@users.noreply.github.com>2013-10-11 00:24:25 -0700
commit7a63d5e50b0ae16a38e673867abd6043d4becc07 (patch)
tree6d174d12a0de707ed8f875801a8dbc0c35f70d3f /mod/webpages.php
parentc2a88c3e4858e3eb2c553bdc775d2f684b0d46b4 (diff)
parent89fc319c900873be58fa677707518646f6c79eec (diff)
downloadvolse-hubzilla-7a63d5e50b0ae16a38e673867abd6043d4becc07.tar.gz
volse-hubzilla-7a63d5e50b0ae16a38e673867abd6043d4becc07.tar.bz2
volse-hubzilla-7a63d5e50b0ae16a38e673867abd6043d4becc07.zip
Merge pull request #2 from friendica/master
Upgraded to latest red
Diffstat (limited to 'mod/webpages.php')
-rw-r--r--mod/webpages.php19
1 files changed, 18 insertions, 1 deletions
diff --git a/mod/webpages.php b/mod/webpages.php
index fb133eccf..04c2e07c5 100644
--- a/mod/webpages.php
+++ b/mod/webpages.php
@@ -41,21 +41,38 @@ function webpages_content(&$a) {
return;
}
+ if(local_user() && local_user() == $owner) {
+ $a->set_widget('design',design_tools());
+ }
+
+
+ $mimetype = get_config('system','page_mimetype');
+ if(! $mimetype)
+ $mimetype = 'choose';
+
+ $layout = get_config('system','page_layout');
+ if(! $layout)
+ $layout = 'choose';
+
+
// Create a status editor (for now - we'll need a WYSIWYG eventually) to create pages
// Nickname is set to the observers xchan, and profile_uid to the owners. This lets you post pages at other people's channels.
require_once ('include/conversation.php');
$x = array(
- 'webpage' => 1,
+ 'webpage' => ITEM_WEBPAGE,
'is_owner' => true,
'nickname' => $a->profile['channel_address'],
'lockstate' => (($group || $cid || $channel['channel_allow_cid'] || $channel['channel_allow_gid'] || $channel['channel_deny_cid'] || $channel['channel_deny_gid']) ? 'lock' : 'unlock'),
'bang' => (($group || $cid) ? '!' : ''),
'visitor' => 'block',
'profile_uid' => intval($owner),
+ 'mimetype' => $mimetype,
+ 'layout' => $layout,
);
$o .= 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.
//TODO - this should be replaced with pagelist_widget