From: <var...@us...> - 2014-07-04 11:53:26
|
Revision: 8953 http://sourceforge.net/p/phpwiki/code/8953 Author: vargenau Date: 2014-07-04 11:53:19 +0000 (Fri, 04 Jul 2014) Log Message: ----------- wiki: use correct headers hierarchy Modified Paths: -------------- trunk/lib/plugin/DebugAuthInfo.php trunk/lib/plugin/DebugBackendInfo.php trunk/lib/plugin/DebugGroupInfo.php Modified: trunk/lib/plugin/DebugAuthInfo.php =================================================================== --- trunk/lib/plugin/DebugAuthInfo.php 2014-07-03 09:11:04 UTC (rev 8952) +++ trunk/lib/plugin/DebugAuthInfo.php 2014-07-04 11:53:19 UTC (rev 8953) @@ -56,7 +56,7 @@ $this->disabled("! user->isAdmin"); } - $html = HTML(HTML::h3(fmt("General Auth Settings"))); + $html = HTML(HTML::h2(fmt("General Auth Settings"))); $table = HTML::table(array('class' => 'bordered')); $table->pushContent($this->show_hash("AUTH DEFINES", $this->buildConstHash( @@ -89,7 +89,7 @@ unset($DBAuthParams['dummy']); $table->pushContent($this->show_hash("\$DBAuthParams[]", $DBAuthParams)); $html->pushContent($table); - $html->pushContent(HTML(HTML::h3(fmt("Personal Auth Settings for “%s”", $userid)))); + $html->pushContent(HTML(HTML::h2(fmt("Personal Auth Settings for “%s”", $userid)))); if (!$user) { $html->pushContent(HTML::p(fmt("No userid"))); } else { @@ -131,9 +131,9 @@ if ($heading) $rows[] = HTML::tr(array( - 'style' => 'color:#000;background-color:#ffcccc'), + 'style' => 'color:black; background-color:#ffcccc'), HTML::td(array('colspan' => 2, - 'style' => 'color:#000'), + 'style' => 'color:black'), $heading)); if (is_object($hash)) $hash = obj2hash($hash); @@ -162,12 +162,11 @@ } } $rows[] = HTML::tr(HTML::td(array('class' => 'align-right', - 'bgcolor' => '#ccc', - 'style' => 'color:#000000'), + 'style' => 'color:black; background-color:#ccc'), HTML(HTML::raw(' '), $key, HTML::raw(' '))), - HTML::td(array('bgcolor' => '#fff', - 'style' => 'color:#000000'), + HTML::td(array( + 'style' => 'color:black; background-color:white'), $val ? $val : HTML::raw(' ')) ); //if (empty($seen[$key])) $seen[$key] = 1; Modified: trunk/lib/plugin/DebugBackendInfo.php =================================================================== --- trunk/lib/plugin/DebugBackendInfo.php 2014-07-03 09:11:04 UTC (rev 8952) +++ trunk/lib/plugin/DebugBackendInfo.php 2014-07-04 11:53:19 UTC (rev 8953) @@ -41,6 +41,16 @@ { $args = $this->getArgs($argstr, $request); extract($args); + if (empty($userid) or $userid == $request->_user->UserName()) { + $user = $request->_user; + $userid = $user->UserName(); + } else { + $user = WikiUser($userid); + } + if (!$user->isAdmin() and !(DEBUG && _DEBUG_LOGIN)) { + $request->_notAuthorized(WIKIAUTH_ADMIN); + $this->disabled("! user->isAdmin"); + } if (empty($page)) return $this->error("page missing"); @@ -49,7 +59,7 @@ $this->readonly_pagemeta = array(); $this->hidden_pagemeta = array('_cached_html'); - $html = HTML(HTML::h3(fmt("Querying backend directly for “%s”", + $html = HTML(HTML::h2(fmt("Querying backend directly for “%s”", $page))); $table = HTML::table(array('class' => 'bordered')); @@ -159,20 +169,20 @@ $rows = array(); if ($heading) $rows[] = HTML::tr(array( - 'style' => 'color:#000;background-color:#ffcccc'), + 'style' => 'color:black; background-color:#ffcccc'), HTML::td(array('colspan' => 2, - 'style' => 'color:#000'), + 'style' => 'color:black'), $heading)); if (!is_array($hash)) return array(); ksort($hash); foreach ($hash as $key => $val) { if ($this->chunk_split and is_string($val)) $val = chunk_split($val); $rows[] = HTML::tr(HTML::td(array('class' => 'align-right', - 'style' => 'color:#000;background-color:#ccc'), + 'style' => 'color:black; background-color:#ccc'), HTML(HTML::raw(' '), $key, HTML::raw(' '))), HTML::td(array( - 'style' => 'color:#000;background-color:#fff'), + 'style' => 'color:black; background-color:white'), $this->_showvalue($key, $val, $prefix)) ); } Modified: trunk/lib/plugin/DebugGroupInfo.php =================================================================== --- trunk/lib/plugin/DebugGroupInfo.php 2014-07-03 09:11:04 UTC (rev 8952) +++ trunk/lib/plugin/DebugGroupInfo.php 2014-07-04 11:53:19 UTC (rev 8953) @@ -48,7 +48,7 @@ foreach ($allGroups as $g) { $members = $group->getMembersOf($g); - $output->pushContent(HTML::h3($g . " - members: " . + $output->pushContent(HTML::h2($g . " - members: " . sizeof($members) . " - isMember: " . ($group->isMember($g) ? "yes" : "no") )); foreach ($members as $m) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |