From: <var...@us...> - 2013-04-16 14:57:17
|
Revision: 8755 http://sourceforge.net/p/phpwiki/code/8755 Author: vargenau Date: 2013-04-16 14:57:15 +0000 (Tue, 16 Apr 2013) Log Message: ----------- private --> protected Modified Paths: -------------- trunk/lib/plugin/BlogArchives.php trunk/lib/plugin/BlogJournal.php trunk/lib/plugin/WikiBlog.php trunk/lib/plugin/WikiFormRich.php Modified: trunk/lib/plugin/BlogArchives.php =================================================================== --- trunk/lib/plugin/BlogArchives.php 2013-04-16 14:55:33 UTC (rev 8754) +++ trunk/lib/plugin/BlogArchives.php 2013-04-16 14:57:15 UTC (rev 8755) @@ -88,7 +88,7 @@ // unset($pagelist->_columns['pagename']); if (!empty($args['month'])) { - $prefix = $parent . $this->_blogPrefix('wikiblog') . SUBPAGE_SEPARATOR . $args['month']; + $prefix = $parent . $this->blogPrefix('wikiblog') . SUBPAGE_SEPARATOR . $args['month']; $pages = $dbi->titleSearch(new TextSearchQuery("^" . $prefix, true, 'posix')); $html = HTML::ul(); while ($page = $pages->next()) { @@ -98,7 +98,7 @@ $html->pushContent(HTML::li(WikiLink($page, 'known', $rev->get('summary')))); } if (!$args['noheader']) - return HTML(HTML::h3(sprintf(_("Blog Entries for %s:"), $this->_monthTitle($args['month']))), + return HTML(HTML::h3(sprintf(_("Blog Entries for %s:"), $this->monthTitle($args['month']))), $html); else return $html; @@ -118,11 +118,11 @@ $mon = $blog['month']; if (empty($months[$mon])) $months[$mon] = - array('title' => $this->_monthTitle($mon), + array('title' => $this->monthTitle($mon), 'num' => 1, 'month' => $mon, 'link' => WikiURL($basepage, - $this->_nonDefaultArgs(array('month' => $mon)))); + $this->nonDefaultArgs(array('month' => $mon)))); else $months[$mon]['num']++; } Modified: trunk/lib/plugin/BlogJournal.php =================================================================== --- trunk/lib/plugin/BlogJournal.php 2013-04-16 14:55:33 UTC (rev 8754) +++ trunk/lib/plugin/BlogJournal.php 2013-04-16 14:57:15 UTC (rev 8755) @@ -79,7 +79,7 @@ } $parent = (empty($args['user']) ? '' : $args['user'] . SUBPAGE_SEPARATOR); - $prefix = $base = $parent . $this->_blogPrefix('wikiblog'); + $prefix = $base = $parent . $this->blogPrefix('wikiblog'); if ($args['month']) $prefix .= (SUBPAGE_SEPARATOR . $args['month']); $pages = $dbi->titleSearch(new TextSearchQuery("^" . $prefix . SUBPAGE_SEPARATOR, true, 'posix')); @@ -100,7 +100,7 @@ if (!$i) return HTML(HTML::h3(_("No Blog Entries")), $html); if (!$args['noheader']) - return HTML(HTML::h3(sprintf(_("Blog Entries for %s:"), $this->_monthTitle($args['month']))), + return HTML(HTML::h3(sprintf(_("Blog Entries for %s:"), $this->monthTitle($args['month']))), $html); else return $html; Modified: trunk/lib/plugin/WikiBlog.php =================================================================== --- trunk/lib/plugin/WikiBlog.php 2013-04-16 14:55:33 UTC (rev 8754) +++ trunk/lib/plugin/WikiBlog.php 2013-04-16 14:57:15 UTC (rev 8755) @@ -196,7 +196,7 @@ $saved = false; if ($type != 'wikiforum') - $pagename = $this->_blogPrefix($type); + $pagename = $this->blogPrefix($type); else { $pagename = substr($summary, 0, 12); if (empty($pagename)) { @@ -286,14 +286,14 @@ if ($args['order'] == 'reverse') $blogs = array_reverse($blogs); - $name = $this->_blogPrefix($type); + $name = $this->blogPrefix($type); if (!$args['noheader']) $html->pushContent(HTML::h4(array('class' => "$type-heading"), fmt("%s on %s:", $name, WikiLink($basepage)))); foreach ($blogs as $rev) { if (!$rev->get($type)) { // Ack! this is an old-style blog with data ctime in page meta-data. - $content = $this->_transformOldFormatBlog($rev, $type); + $content = $this->transformOldFormatBlog($rev, $type); } else { $content = $rev->getTransformedContent($type); } @@ -306,7 +306,7 @@ // Subpage for the basepage. All Blogs/Forum/Comment entries are // Subpages under this pagename, to find them faster. - private function _blogPrefix($type = 'wikiblog') + protected function blogPrefix($type = 'wikiblog') { if ($type == 'wikiblog') $basepage = "Blog"; @@ -317,7 +317,7 @@ return $basepage; } - private function _transformOldFormatBlog($rev, $type = 'wikiblog') + private function transformOldFormatBlog($rev, $type = 'wikiblog') { $page = $rev->getPage(); $metadata = array(); @@ -334,7 +334,7 @@ { $prefix = (empty($basepage) ? "" - : $basepage . SUBPAGE_SEPARATOR) . $this->_blogPrefix($type); + : $basepage . SUBPAGE_SEPARATOR) . $this->blogPrefix($type); $pages = $dbi->titleSearch(new TextSearchQuery('"' . $prefix . '"', true, 'none')); $blogs = array(); @@ -370,7 +370,7 @@ } // "2004-12" => "December 2004" - private function _monthTitle($month) + protected function monthTitle($month) { if (!$month) $month = strftime("%Y-%m"); //list($year,$mon) = explode("-",$month); @@ -378,7 +378,7 @@ } // "UserName/Blog/2004-12-13/12:28:50+01:00" => array('month' => "2004-12", ...) - private function _blog($rev_or_page) + protected function _blog($rev_or_page) { $pagename = $rev_or_page->getName(); if (preg_match("/^(.*Blog)\/(\d\d\d\d-\d\d)-(\d\d)\/(.*)/", $pagename, $m)) @@ -386,14 +386,14 @@ return array('pagename' => $pagename, // page (list pages per month) or revision (list months)? //'title' => isa($rev_or_page,'WikiDB_PageRevision') ? $rev_or_page->get('summary') : '', - //'monthtitle' => $this->_monthTitle($month), + //'monthtitle' => $this->monthTitle($month), 'month' => $month, 'day' => $day, 'time' => $time, 'prefix' => $prefix); } - private function _nonDefaultArgs($args) + protected function nonDefaultArgs($args) { return array_diff_assoc($args, $this->getDefaultArguments()); } Modified: trunk/lib/plugin/WikiFormRich.php =================================================================== --- trunk/lib/plugin/WikiFormRich.php 2013-04-16 14:55:33 UTC (rev 8754) +++ trunk/lib/plugin/WikiFormRich.php 2013-04-16 14:57:15 UTC (rev 8755) @@ -238,7 +238,7 @@ if (empty($input['value']) and ($s = $request->getArg($input['name']))) $input['value'] = $s; if (!empty($input['autocomplete'])) - $this->_doautocomplete($form, $inputtype, $input, $input['value']); + $this->do_autocomplete($form, $inputtype, $input, $input['value']); if ($nobr) $form->pushContent($text, $nbsp, HTML::input($input)); else @@ -252,7 +252,7 @@ unset($input['type']); if (is_string($values)) $values = explode(",", $values); if (!empty($input['autocomplete'])) - $this->_doautocomplete($form, $inputtype, $input, $values); + $this->do_autocomplete($form, $inputtype, $input, $values); $select = HTML::select($input); if (empty($values) and ($s = $request->getArg($input['name']))) { $select->pushContent(HTML::option(array('value' => $s), $s)); @@ -318,7 +318,7 @@ return $form; } - private function _doautocomplete(&$form, $inputtype, &$input, &$values) + private function do_autocomplete(&$form, $inputtype, &$input, &$values) { global $request; $input['class'] = "dropdown"; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |