From e06c3e5a911176bd2afc5d9d391e629f282122b8 Mon Sep 17 00:00:00 2001 From: Jeroen Date: Thu, 9 Oct 2014 14:54:04 +0000 Subject: Added and changed on some places div class generic-content-wrapper. And added to redbasic. Other thems can now also theme backgrounds of a lot of pages. I'm not completely done, but till now - this is it. --- mod/webpages.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'mod/webpages.php') diff --git a/mod/webpages.php b/mod/webpages.php index efaf3c4bf..341e75a0c 100644 --- a/mod/webpages.php +++ b/mod/webpages.php @@ -81,6 +81,8 @@ function webpages_content(&$a) { require_once('include/conversation.php'); $o = profile_tabs($a,true); + $o .= '
'; + $o .= '

' . t('Webpages') . '

'; $x = array( @@ -95,7 +97,7 @@ function webpages_content(&$a) { 'mimetype' => $mimetype, 'layout' => $layout, ); - + if($_REQUEST['title']) $x['title'] = $_REQUEST['title']; if($_REQUEST['body']) @@ -105,7 +107,6 @@ function webpages_content(&$a) { $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 @@ -142,5 +143,6 @@ function webpages_content(&$a) { )); + $o .= '
'; } -- cgit v1.2.3 From 4e9bd8b8f0a2629cf1ad7c7274369e795852a8ab Mon Sep 17 00:00:00 2001 From: marijus Date: Fri, 10 Oct 2014 15:52:56 +0200 Subject: This is a fix to not interfere the ongoing adding of .generic-content-wrapper with the ongoing styling of redbasic theme. adding of .generic-content-wrapper is needed and useful for derivative themes but it should not contain any styling information for redbasic theme. therefor i added .generic-content-wrapper-styled as a quickfix for spots where redbasic is not finished yet. Sidenote: please avoid opening a div in one *.tpl and close it in another or (even worse) open a div in a *.tpl and close it in an already templatified mod/*.php. This will really make the code and templates very, very confusing. --- mod/webpages.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mod/webpages.php') diff --git a/mod/webpages.php b/mod/webpages.php index 341e75a0c..2c3cc36ea 100644 --- a/mod/webpages.php +++ b/mod/webpages.php @@ -81,7 +81,7 @@ function webpages_content(&$a) { require_once('include/conversation.php'); $o = profile_tabs($a,true); - $o .= '
'; + $o .= '
'; $o .= '

' . t('Webpages') . '

'; -- cgit v1.2.3 From d132646915a3cf500215e7323b29a3e26670be10 Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Sat, 11 Oct 2014 15:42:31 +0100 Subject: Unbreak webpages --- mod/webpages.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'mod/webpages.php') diff --git a/mod/webpages.php b/mod/webpages.php index 2c3cc36ea..6fee8b414 100644 --- a/mod/webpages.php +++ b/mod/webpages.php @@ -81,9 +81,6 @@ function webpages_content(&$a) { require_once('include/conversation.php'); $o = profile_tabs($a,true); - $o .= '
'; - - $o .= '

' . t('Webpages') . '

'; $x = array( 'webpage' => ITEM_WEBPAGE, @@ -129,6 +126,7 @@ function webpages_content(&$a) { $url = z_root() . "/editwebpage/" . $which; // This isn't pretty, but it works. Until I figure out what to do with the UI, it's Good Enough(TM). return $o . replace_macros(get_markup_template("webpagelist.tpl"), array( + '$listtitle = t('Webpages'), '$baseurl' => $url, '$edit' => t('Edit'), '$pages' => $pages, -- cgit v1.2.3 From d46fd7917f248c105ca44d2d15878d79b358fdfd Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Sat, 11 Oct 2014 16:18:15 +0100 Subject: Fix webpages. Sycning between too many codebases... --- mod/webpages.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'mod/webpages.php') diff --git a/mod/webpages.php b/mod/webpages.php index 6fee8b414..f1be648ff 100644 --- a/mod/webpages.php +++ b/mod/webpages.php @@ -35,6 +35,8 @@ function webpages_content(&$a) { $ob_hash = (($observer) ? $observer['xchan_hash'] : ''); $perms = get_all_perms($owner,$ob_hash); + if ($which == 'sys' && is_site_admin()) + $perms['write_pages'] = 1; if(! $perms['write_pages']) { notice( t('Permission denied.') . EOL); @@ -126,7 +128,7 @@ function webpages_content(&$a) { $url = z_root() . "/editwebpage/" . $which; // This isn't pretty, but it works. Until I figure out what to do with the UI, it's Good Enough(TM). return $o . replace_macros(get_markup_template("webpagelist.tpl"), array( - '$listtitle = t('Webpages'), + '$listtitle' => t('Webpages'), '$baseurl' => $url, '$edit' => t('Edit'), '$pages' => $pages, -- cgit v1.2.3 From b84b2d5aa50a58e0ca85d56e02a83bdfbc3d9cde Mon Sep 17 00:00:00 2001 From: Thomas Willingham Date: Sat, 11 Oct 2014 16:19:36 +0100 Subject: FFS, another oops --- mod/webpages.php | 2 -- 1 file changed, 2 deletions(-) (limited to 'mod/webpages.php') diff --git a/mod/webpages.php b/mod/webpages.php index f1be648ff..a5cfd00e6 100644 --- a/mod/webpages.php +++ b/mod/webpages.php @@ -35,8 +35,6 @@ function webpages_content(&$a) { $ob_hash = (($observer) ? $observer['xchan_hash'] : ''); $perms = get_all_perms($owner,$ob_hash); - if ($which == 'sys' && is_site_admin()) - $perms['write_pages'] = 1; if(! $perms['write_pages']) { notice( t('Permission denied.') . EOL); -- cgit v1.2.3