From: <var...@us...> - 2010-12-16 12:52:17
|
Revision: 7780 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7780&view=rev Author: vargenau Date: 2010-12-16 12:52:11 +0000 (Thu, 16 Dec 2010) Log Message: ----------- forcvs --> forsvn Modified Paths: -------------- trunk/lib/plugin/PageDump.php Modified: trunk/lib/plugin/PageDump.php =================================================================== --- trunk/lib/plugin/PageDump.php 2010-12-16 12:48:00 UTC (rev 7779) +++ trunk/lib/plugin/PageDump.php 2010-12-16 12:52:11 UTC (rev 7780) @@ -36,7 +36,7 @@ * * Usage: * Direct URL access: - * http://...phpwiki/PageDump?page=HomePage?format=forcvs + * http://...phpwiki/PageDump?page=HomePage?format=forsvn * http://...phpwiki/index.php?PageDump&page=HomePage * http://...phpwiki/index.php?PageDump&page=HomePage&download=1 * Static: @@ -63,7 +63,7 @@ return array('s' => false, 'page' => '[pagename]', //'encoding' => 'binary', // 'binary', 'quoted-printable' - 'format' => false, // 'normal', 'forcvs', 'backup' + 'format' => false, // 'normal', 'forsvn', 'forcvs', 'backup' // display within WikiPage or give a downloadable // raw pgsrc? 'download' => false); @@ -91,7 +91,7 @@ $mailified = MailifyPage($p, ($format == 'backup') ? 99 : 1); // fixup_headers massages the page dump headers depending on - // the 'format' argument, 'normal'(default) or 'forcvs'. + // the 'format' argument, 'normal'(default) or 'forsvn'. // // Normal: Don't add X-Rcs-Id, add unique Message-Id, don't // strip any fields from Content-Type. @@ -102,8 +102,8 @@ $this->pagename = $page; $this->generateMessageId($mailified); - if ($format == 'forcvs') - $this->fixup_headers_forcvs($mailified); + if (($format == 'forsvn') || ($format == 'forcvs')) + $this->fixup_headers_forsvn($mailified); else // backup or normal $this->fixup_headers($mailified); @@ -142,9 +142,9 @@ // text if it is too long--unless quoted-printable (TODO). $mailified = wordwrap($mailified, 70); - $dlcvs = Button(array(//'page' => $page, + $dlsvn = Button(array(//'page' => $page, 'action' => $this->getName(), - 'format'=> 'forcvs', + 'format'=> 'forsvn', 'download'=> true), _("Download for Subversion"), $page); @@ -166,7 +166,7 @@ if (!$Sep = $WikiTheme->getButtonSeparator()) $Sep = " "; - if ($format == 'forcvs') { + if ($format == 'forsvn') { $desc = _("(formatted for PhpWiki developers as pgsrc template, not for backing up)"); $altpreviewbuttons = HTML( Button(array('action' => $this->getName()), @@ -183,7 +183,7 @@ $desc = _("(formatted for backing up: all revisions)"); // all revisions $altpreviewbuttons = HTML( Button(array('action' => $this->getName(), - 'format'=> 'forcvs'), + 'format'=> 'forsvn'), _("Preview as developer format"), $page), $Sep, @@ -196,7 +196,7 @@ $desc = _("(normal formatting: latest revision only)"); $altpreviewbuttons = HTML( Button(array('action' => $this->getName(), - 'format'=> 'forcvs'), + 'format'=> 'forsvn'), _("Preview as developer format"), $page), $Sep, @@ -222,7 +222,7 @@ HTML::div(array('class' => 'errors'), HTML::strong(_("Warning:")), " ", $warning), - $dl, $Sep, $dlall, $Sep, $dlcvs + $dl, $Sep, $dlall, $Sep, $dlsvn ); } @@ -269,7 +269,7 @@ $mailified = implode("\n", array_values($return)); } - function fixup_headers_forcvs(&$mailified) { + function fixup_headers_forsvn(&$mailified) { $array = explode("\n", $mailified); // Massage headers to prepare for developer checkin to Subversion. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <var...@us...> - 2010-12-16 13:04:48
|
Revision: 7779 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7779&view=rev Author: vargenau Date: 2010-12-16 12:48:00 +0000 (Thu, 16 Dec 2010) Log Message: ----------- CVS --> Subversion Modified Paths: -------------- trunk/lib/plugin/PageDump.php Modified: trunk/lib/plugin/PageDump.php =================================================================== --- trunk/lib/plugin/PageDump.php 2010-12-16 11:56:28 UTC (rev 7778) +++ trunk/lib/plugin/PageDump.php 2010-12-16 12:48:00 UTC (rev 7779) @@ -22,7 +22,7 @@ /** * PhpWikiPlugin for PhpWiki developers to generate single page dumps - * for checking into cvs, or for users or the admin to produce a + * for checking into Subversion, or for users or the admin to produce a * downloadable page dump of a single page. * * This plugin will also be useful to (semi-)automatically sync pages @@ -146,7 +146,7 @@ 'action' => $this->getName(), 'format'=> 'forcvs', 'download'=> true), - _("Download for CVS"), + _("Download for Subversion"), $page); $dl = Button(array(//'page' => $page, 'action' => $this->getName(), @@ -212,7 +212,7 @@ _("The wordwrap of the preview doesn't take nested markup or list indentation into consideration!") . " ", HTML::em( -_("PhpWiki developers should manually inspect the downloaded file for nested markup before rewrapping with emacs and checking into CVS.") +_("PhpWiki developers should manually inspect the downloaded file for nested markup before rewrapping with emacs and checking into Subversion.") ) ); @@ -272,7 +272,7 @@ function fixup_headers_forcvs(&$mailified) { $array = explode("\n", $mailified); - // Massage headers to prepare for developer checkin to CVS. + // Massage headers to prepare for developer checkin to Subversion. $item_to_insert = "X-Rcs-Id: \$Id\$"; $insert_into_key_position = 2; $returnval_ignored = array_splice($array, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <var...@us...> - 2011-01-21 14:50:05
|
Revision: 7857 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7857&view=rev Author: vargenau Date: 2011-01-21 14:49:59 +0000 (Fri, 21 Jan 2011) Log Message: ----------- @ob_end_flush Modified Paths: -------------- trunk/lib/plugin/PageDump.php Modified: trunk/lib/plugin/PageDump.php =================================================================== --- trunk/lib/plugin/PageDump.php 2011-01-21 14:48:27 UTC (rev 7856) +++ trunk/lib/plugin/PageDump.php 2011-01-21 14:49:59 UTC (rev 7857) @@ -112,7 +112,7 @@ // Content-Type, Set-Cookie, Cache-control, ... $request->discardOutput(); // Hijack the http request from PhpWiki. ob_end_clean(); // clean up after hijacking $request - //ob_end_flush(); //debugging + //while (@ob_end_flush()); //debugging $filename = FilenameForPage($page); Header("Content-disposition: attachment; filename=\"" . $filename . "\""); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <var...@us...> - 2012-12-11 15:49:02
|
Revision: 8646 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=8646&view=rev Author: vargenau Date: 2012-12-11 15:48:55 +0000 (Tue, 11 Dec 2012) Log Message: ----------- No return after exit Modified Paths: -------------- trunk/lib/plugin/PageDump.php Modified: trunk/lib/plugin/PageDump.php =================================================================== --- trunk/lib/plugin/PageDump.php 2012-12-11 15:21:43 UTC (rev 8645) +++ trunk/lib/plugin/PageDump.php 2012-12-11 15:48:55 UTC (rev 8646) @@ -140,8 +140,7 @@ // Here comes our prepared mime file echo $mailified; - exit; // noreturn! php exits. - return; + exit(); // noreturn! php exits. } // We are displaing inline preview in a WikiPage, so wrap the // text if it is too long--unless quoted-printable (TODO). This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <var...@us...> - 2012-12-11 16:44:37
|
Revision: 8651 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=8651&view=rev Author: vargenau Date: 2012-12-11 16:44:31 +0000 (Tue, 11 Dec 2012) Log Message: ----------- Better error message Modified Paths: -------------- trunk/lib/plugin/PageDump.php Modified: trunk/lib/plugin/PageDump.php =================================================================== --- trunk/lib/plugin/PageDump.php 2012-12-11 16:27:24 UTC (rev 8650) +++ trunk/lib/plugin/PageDump.php 2012-12-11 16:44:31 UTC (rev 8651) @@ -77,13 +77,15 @@ { extract($this->getArgs($argstr, $request)); // allow plugin-form - if (!empty($s)) + if (!empty($s)) { $page = $s; - if (!$page) + } + if (!$page) { return ''; - if (!$dbi->isWikiPage($page)) - return fmt("Page %s not found.", - WikiLink($page, 'unknown')); + } + if (!$dbi->isWikiPage($page)) { + return $this->error(sprintf(_("Page “%s” does not exist."), $page)); + } // Check if user is allowed to get the Page. if (!mayAccessPage('view', $page)) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <var...@us...> - 2022-01-05 12:31:06
|
Revision: 10820 http://sourceforge.net/p/phpwiki/code/10820 Author: vargenau Date: 2022-01-05 12:31:05 +0000 (Wed, 05 Jan 2022) Log Message: ----------- PageDump plugin: it's a warning Modified Paths: -------------- trunk/lib/plugin/PageDump.php Modified: trunk/lib/plugin/PageDump.php =================================================================== --- trunk/lib/plugin/PageDump.php 2022-01-05 12:22:19 UTC (rev 10819) +++ trunk/lib/plugin/PageDump.php 2022-01-05 12:31:05 UTC (rev 10820) @@ -213,8 +213,8 @@ return HTML($h2, HTML::em($desc), HTML::pre($mailified), $altpreviewbuttons, - HTML::div(array('class' => 'error'), - HTML::strong(_("Warning")), _(": "), $warning), + HTML::div(array('class' => 'warning'), + HTML::strong(_("Warning")._(": ")), $warning), $dl, $Sep, $dlall, $Sep, $dlsvn ); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |