From: <var...@us...> - 2014-07-31 14:40:34
|
Revision: 9045 http://sourceforge.net/p/phpwiki/code/9045 Author: vargenau Date: 2014-07-31 14:40:26 +0000 (Thu, 31 Jul 2014) Log Message: ----------- Remove unused template nochanges.tmpl Modified Paths: -------------- trunk/lib/editpage.php trunk/themes/default/templates/categorypage.tmpl trunk/themes/wikilens/templates/categorypage.tmpl Removed Paths: ------------- trunk/themes/default/templates/nochanges.tmpl Modified: trunk/lib/editpage.php =================================================================== --- trunk/lib/editpage.php 2014-07-31 14:20:18 UTC (rev 9044) +++ trunk/lib/editpage.php 2014-07-31 14:40:26 UTC (rev 9045) @@ -118,7 +118,6 @@ elseif ($this->editaction == 'keep_old') { // keep old page and do nothing $this->_redirectToBrowsePage(); - //$r->redirect(WikiURL($r->getArg('save_and_redirect_to'))); return true; } elseif ($this->editaction == 'overwrite') { // take the new content without diff @@ -129,7 +128,6 @@ $this->request->setArg('merge', 0); LoadFileOrDir($this->request); $this->_redirectToBrowsePage(); - //$r->redirect(WikiURL($r->getArg('save_and_redirect_to'))); return true; } elseif ($this->editaction == 'upload') { // run plugin UpLoad @@ -280,28 +278,12 @@ } // Save failed. No changes made. $this->_redirectToBrowsePage(); - // user will probably not see the rest of this... - require_once 'lib/display.php'; - // force browse of current version: - $request->setArg('action', false); - $request->setArg('version', false); - displayPage($request, 'nochanges'); return true; } if (!$this->user->isAdmin() and $this->isSpam()) { $this->_isSpam = true; return false; - /* - // Save failed. No changes made. - $this->_redirectToBrowsePage(); - // user will probably not see the rest of this... - require_once 'lib/display.php'; - // force browse of current version: - $request->setArg('version', false); - displayPage($request, 'nochanges'); - return true; - */ } $page = &$this->page; @@ -351,6 +333,7 @@ // (below). $request->setArg('action', false); $this->_redirectToBrowsePage(); + return true; } // Force browse of current page version. @@ -733,7 +716,7 @@ return $el; } - function _redirectToBrowsePage() + private function _redirectToBrowsePage() { $this->request->redirect(WikiURL($this->page, false, 'absolute_url')); } Modified: trunk/themes/default/templates/categorypage.tmpl =================================================================== --- trunk/themes/default/templates/categorypage.tmpl 2014-07-31 14:20:18 UTC (rev 9044) +++ trunk/themes/default/templates/categorypage.tmpl 2014-07-31 14:40:26 UTC (rev 9045) @@ -31,11 +31,7 @@ $initial_content = "\"This page is in the $bpage category. You must leave in at least one reference to $bpage in order for this page to be in the $bpage category. Otherwise, edit this text to describe your page.\""; $adder = ""; - - //if($SELF_ON_CREATE == true){ - //$adder = "save_and_redirect_to=\"" . $PAGENAME . "\""; - //} - + $this->_printPlugin("<" . "?plugin-form CreatePage " . $adder . " initial_content=" . $initial_content . " ?" . ">"); ?> Deleted: trunk/themes/default/templates/nochanges.tmpl =================================================================== --- trunk/themes/default/templates/nochanges.tmpl 2014-07-31 14:20:18 UTC (rev 9044) +++ trunk/themes/default/templates/nochanges.tmpl 2014-07-31 14:40:26 UTC (rev 9045) @@ -1,6 +0,0 @@ -<p><strong><?php echo _("Edit aborted.")?></strong> -<?php echo _("You have not made any changes so no new version has been saved.")?></p> -<?php if (!empty($LOCK_CHANGED_MSG)) { ?> - <p><?php echo $LOCK_CHANGED_MSG?></p> -<?php } ?> -<?php echo Template('browse') ?> Modified: trunk/themes/wikilens/templates/categorypage.tmpl =================================================================== --- trunk/themes/wikilens/templates/categorypage.tmpl 2014-07-31 14:20:18 UTC (rev 9044) +++ trunk/themes/wikilens/templates/categorypage.tmpl 2014-07-31 14:40:26 UTC (rev 9045) @@ -12,21 +12,21 @@ $this->_printPlugin("<" . "?plugin UserRatings nobuds=" . ($SHOWBUDS ? 0 : 1) . " category=\"" . $PAGENAME . "\" ?" . ">"); ?> <br/> -<?php +<?php if ($SHOWBUDS){ - $btn = Button(array('exclude' => "$EXCLUDE", + $btn = Button(array('exclude' => "$EXCLUDE", 'category' => "$PAGENAME", 'showbuds' => false), - _("Hide Buddy Ratings in the $SINGULAR category"), - $PAGENAME); + _("Hide Buddy Ratings in the $SINGULAR category"), + $PAGENAME); } else { -$btn = Button(array('exclude' => "$EXCLUDE", +$btn = Button(array('exclude' => "$EXCLUDE", 'category' => "$PAGENAME", 'showbuds' => true), - _("Show Buddy Ratings in the $SINGULAR category"), - $PAGENAME); + _("Show Buddy Ratings in the $SINGULAR category"), + $PAGENAME); } ?> <?php echo $btn ?> @@ -56,11 +56,7 @@ $initial_content = "\"This page is in the $bpage category. You must leave in at least one reference to $bpage in order for this page to be in the $bpage category. Otherwise, edit this text to describe your page.\""; $adder = ""; - - //if($SELF_ON_CREATE == true){ - //$adder = "save_and_redirect_to=\"" . $PAGENAME . "\""; - //} - + $this->_printPlugin("<" . "?plugin-form CreatePage " . $adder . " initial_content=" . $initial_content . " ?" . ">"); ?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |