From: <var...@us...> - 2021-02-22 18:37:24
|
Revision: 10257 http://sourceforge.net/p/phpwiki/code/10257 Author: vargenau Date: 2021-02-22 18:37:22 +0000 (Mon, 22 Feb 2021) Log Message: ----------- plugin LinkSearch: better test boolean arguments "noform" and "noheader" Modified Paths: -------------- trunk/lib/plugin/LinkSearch.php Modified: trunk/lib/plugin/LinkSearch.php =================================================================== --- trunk/lib/plugin/LinkSearch.php 2021-02-22 18:28:34 UTC (rev 10256) +++ trunk/lib/plugin/LinkSearch.php 2021-02-22 18:37:22 UTC (rev 10257) @@ -137,6 +137,22 @@ { $args = $this->getArgs($argstr, $request); + if (($noform == '0') || ($noform == 'false')) { + $noform = false; + } elseif (($noform == '1') || ($noform == 'true')) { + $noform = true; + } else { + return $this->error(sprintf(_("Argument '%s' must be a boolean"), "noform")); + } + + if (($noheader == '0') || ($noheader == 'false')) { + $noheader = false; + } elseif (($noheader == '1') || ($noheader == 'true')) { + $noheader = true; + } else { + return $this->error(sprintf(_("Argument '%s' must be a boolean"), "noheader")); + } + if (empty($args['page'])) $args['page'] = "*"; $form = $this->showForm($dbi, $request, $args); @@ -158,7 +174,7 @@ if (!$noheader) { // We put the form into the caption just to be able to return one pagelist object, // and to still have the convenience form at the top. we could workaround this by - // putting the form as WikiFormRich into the actionpage. but thid doesnt look as + // putting the form as WikiFormRich into the actionpage. But this does not look as // nice as this here. $pagelist->setCaption ( // on mozilla the form doesn't fit into the caption very well. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <var...@us...> - 2021-02-22 18:44:06
|
Revision: 10258 http://sourceforge.net/p/phpwiki/code/10258 Author: vargenau Date: 2021-02-22 18:44:04 +0000 (Mon, 22 Feb 2021) Log Message: ----------- Extract arguments first Modified Paths: -------------- trunk/lib/plugin/LinkSearch.php Modified: trunk/lib/plugin/LinkSearch.php =================================================================== --- trunk/lib/plugin/LinkSearch.php 2021-02-22 18:37:22 UTC (rev 10257) +++ trunk/lib/plugin/LinkSearch.php 2021-02-22 18:44:04 UTC (rev 10258) @@ -136,6 +136,7 @@ function run($dbi, $argstr, &$request, $basepage) { $args = $this->getArgs($argstr, $request); + extract($args); if (($noform == '0') || ($noform == 'false')) { $noform = false; @@ -156,7 +157,6 @@ if (empty($args['page'])) $args['page'] = "*"; $form = $this->showForm($dbi, $request, $args); - extract($args); if (empty($s)) return $form; $pagequery = new TextSearchQuery($page, $args['case_exact'], $args['regex']); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <var...@us...> - 2021-06-17 13:29:29
|
Revision: 10291 http://sourceforge.net/p/phpwiki/code/10291 Author: vargenau Date: 2021-06-17 13:29:29 +0000 (Thu, 17 Jun 2021) Log Message: ----------- method get in lower case Modified Paths: -------------- trunk/lib/plugin/LinkSearch.php Modified: trunk/lib/plugin/LinkSearch.php =================================================================== --- trunk/lib/plugin/LinkSearch.php 2021-06-16 18:53:31 UTC (rev 10290) +++ trunk/lib/plugin/LinkSearch.php 2021-06-17 13:29:29 UTC (rev 10291) @@ -113,7 +113,7 @@ $submit = Button('submit:search', _("LinkSearch"), false); $instructions = _("Search in pages for links with the matching name."); $form = HTML::form(array('action' => $action, - 'method' => 'GET', + 'method' => 'get', 'accept-charset' => 'UTF-8'), $dirsign_switch, $hiddenfield, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |