SourceForge logo
SourceForge logo
Menu

phpwiki-checkins

From: <var...@us...> - 2009年01月07日 18:52:24
Revision: 6376
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=6376&view=rev
Author: vargenau
Date: 2009年01月07日 18:52:15 +0000 (2009年1月07日)
Log Message:
-----------
Use Wikicreole syntax
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年01月07日 09:48:02 UTC (rev 6375)
+++ trunk/lib/EditToolbar.php	2009年01月07日 18:52:15 UTC (rev 6376)
@@ -102,13 +102,13 @@
 $toolarray = array(
 array(
 "image"=>"ed_format_bold.png",
- "open"=>"<strong>",
- "close"=>"</strong>",
+ "open"=>"**",
+ "close"=>"**",
 "sample"=>_("Bold text"),
 "title"=>_("Bold text [alt-b]")),
 array("image"=>"ed_format_italic.png",
- "open"=>"<em>",
- "close"=>"</em>",
+ "open"=>"//",
+ "close"=>"//",
 "sample"=>_("Italic text"),
 "title"=>_("Italic text [alt-i]")),
 array("image"=>"ed_format_strike.png",
@@ -122,18 +122,18 @@
 "sample"=>_("Color text"),
 "title"=>_("Color")),
 array("image"=>"ed_pagelink.png",
- "open"=>"[",
- "close"=>"]",
- "sample"=>_("optional label | PageName"),
+ "open"=>"[[",
+ "close"=>"]]",
+ "sample"=>_("PageName|optional label"),
 "title"=>_("Link to page")),
 array("image"=>"ed_link.png",
- "open"=>"[",
- "close"=>"]",
- "sample"=>_("optional label | http://www.example.com"),
+ "open"=>"[[",
+ "close"=>"]]",
+ "sample"=>_("http://www.example.com|optional label"),
 "title"=>_("External link (remember http:// prefix)")),
 array("image"=>"ed_headline.png",
- "open"=>"\\n!!! ",
- "close"=>"\\n",
+ "open"=>"\\n== ",
+ "close"=>" ==\\n",
 "sample"=>_("Headline text"),
 "title"=>_("Level 1 headline")),
 array("image"=>"ed_nowiki.png",
@@ -152,7 +152,7 @@
 "sample"=>"",
 "title"=>_("Horizontal line")),
 array("image"=>"ed_table.png",
- "open"=>"\\n{| class=\"bordered\"\\n|-\\n| Cell A1 || Cell B1 || Cell C1\\n|-\\n| Cell A2 || Cell B2 || Cell C2\\n|-\\n| Cell A3 || Cell B3 || Cell C3\\n|}\\n",
+ "open"=>"\\n{| class=\"bordered\"\\n|+ This is the table caption\\n|= This is the table summary\\n|-\\n| Cell A1 || Cell B1 || Cell C1\\n|-\\n| Cell A2 || Cell B2 || Cell C2\\n|-\\n| Cell A3 || Cell B3 || Cell C3\\n|}\\n",
 "close"=>"",
 "sample"=>"",
 "title"=>_("Sample table")),
@@ -167,19 +167,19 @@
 "sample"=>"",
 "title"=>_("List")),
 array("image"=>"ed_toc.png",
- "open"=>"<?plugin CreateToc with_toclink||=1 ?>\\n",
+ "open"=>"<<CreateToc with_toclink||=1>>\\n",
 "close"=>"",
 "sample"=>"",
 "title"=>_("Table of Contents")),
 array("image"=>"ed_redirect.png",
- "open"=>"<?plugin RedirectTo page=\"",
- "close"=>"\" ?>",
+ "open"=>"<<RedirectTo page=\"",
+ "close"=>"\">>",
 "sample"=>_("Page Name"),
 "title"=>_("Redirect")),
 array("image"=>"ed_templateplugin.png",
 "open"=>"{{",
 "close"=>"}}",
- "sample"=>_("template name"),
+ "sample"=>_("Template Name"),
 "title"=>_("Template"))
 );
 $btn = new SubmitImageButton(_("Save"), "edit[save]", 'toolbar', 
@@ -281,10 +281,7 @@
 $categories = array();
 while ($p = $pages->next()) {
 		$page = $p->getName();
-		if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($page)))
-		 $categories[] = "['$page', '%5B".$page."%5D']";
-		else
-		 $categories[] = "['$page', '$page']";
+		$categories[] = "['$page', '%5B%5B".$page."%5D%5D']";
 }
 if (!$categories) return '';
 	 // Ensure this to be inserted at the very end. Hence we added the id to the function.
@@ -330,7 +327,7 @@
 $desc = str_replace("<br />",' ',$desc->asXML());
 if ($desc)
 $plugin_args = ' '.str_replace($src, $replace, $desc);
- $toinsert = "%0A<?plugin ".$pluginName.$plugin_args."?>"; // args?
+ $toinsert = "%0A<<".$pluginName.$plugin_args.">>"; // args?
 $plugin_js .= ",['$pluginName','$toinsert']";
 }
 }
@@ -393,7 +390,13 @@
 if (!empty($images)) {
 $image_js = '';
 foreach ($images as $image) {
- $image_js .= ",['$image','%5BUpload:".$image."%5D']";
+ // Select only files ending in ".png", ".gif", ".jpg", ".jpeg"
+ if ((string_ends_with($image, ".jpg"))
+ or (string_ends_with($image, ".jpeg"))
+ or (string_ends_with($image, ".gif"))
+ or (string_ends_with($image, ".png"))) {
+ $image_js .= ",['$image','{{".$image."}}']";
+ }
 }
 $image_js = substr($image_js, 1);
 $more_buttons = HTML::img(array('class'=>"toolbar",
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年02月01日 14:40:45
Revision: 6477
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=6477&view=rev
Author: vargenau
Date: 2009年02月01日 14:40:29 +0000 (2009年2月01日)
Log Message:
-----------
Add header to Sample Table
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年01月31日 19:38:55 UTC (rev 6476)
+++ trunk/lib/EditToolbar.php	2009年02月01日 14:40:29 UTC (rev 6477)
@@ -152,7 +152,7 @@
 "sample"=>"",
 "title"=>_("Horizontal line")),
 array("image"=>"ed_table.png",
- "open"=>"\\n{| class=\"bordered\"\\n|+ This is the table caption\\n|= This is the table summary\\n|-\\n| Cell A1 || Cell B1 || Cell C1\\n|-\\n| Cell A2 || Cell B2 || Cell C2\\n|-\\n| Cell A3 || Cell B3 || Cell C3\\n|}\\n",
+ "open"=>"\\n{| class=\"bordered\"\\n|+ This is the table caption\\n|= This is the table summary\\n|-\\n! Header A !! Header B !! Header C\\n|-\\n| Cell A1 || Cell B1 || Cell C1\\n|-\\n| Cell A2 || Cell B2 || Cell C2\\n|-\\n| Cell A3 || Cell B3 || Cell C3\\n|}\\n",
 "close"=>"",
 "sample"=>"",
 "title"=>_("Sample table")),
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年03月27日 11:54:54
Revision: 6726
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=6726&view=rev
Author: vargenau
Date: 2009年03月27日 11:54:30 +0000 (2009年3月27日)
Log Message:
-----------
Double square brackets for Gforge
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年03月27日 10:48:28 UTC (rev 6725)
+++ trunk/lib/EditToolbar.php	2009年03月27日 11:54:30 UTC (rev 6726)
@@ -284,10 +284,13 @@
 $categories = array();
 while ($p = $pages->next()) {
 		$page = $p->getName();
-		if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($page)))
+ if (defined('GFORGE') and GFORGE) {
+ $categories[] = "['$page', '%5B%5B".$page."%5D%5D']";
+		} else if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($page))) {
 		 $categories[] = "['$page', '%5B".$page."%5D']";
-		else
+		} else {
 		 $categories[] = "['$page', '$page']";
+ }
 }
 if (!$categories) return '';
 	 // Ensure this to be inserted at the very end. Hence we added the id to the function.
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年05月14日 10:01:50
Revision: 6806
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=6806&view=rev
Author: vargenau
Date: 2009年05月14日 10:01:38 +0000 (2009年5月14日)
Log Message:
-----------
Remove history
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年04月25日 18:53:21 UTC (rev 6805)
+++ trunk/lib/EditToolbar.php	2009年05月14日 10:01:38 UTC (rev 6806)
@@ -456,63 +456,6 @@
 
 }
 
-/*
-$Log: not supported by cvs2svn $
-Revision 1.17 2008年08月06日 09:25:56 vargenau
-Button to add images, display in extra window as popup and insert
-
-Revision 1.16 2008年08月03日 15:21:45 vargenau
-Less arguments for CreateToc button
-
-Revision 1.15 2008年04月02日 18:07:05 vargenau
-New Edit Toolbar icons for TOC and Color text
-
-Revision 1.14 2008年02月19日 19:07:23 vargenau
-More icons for toolbar
-
-Revision 1.13 2007年07月14日 12:03:12 rurban
-just aesthetics
-
-Revision 1.12 2007年06月02日 18:23:36 rurban
-Added accesskeys
-
-Revision 1.11 2007年02月17日 14:16:21 rurban
-move define_f after toolbar.js
-
-Revision 1.10 2007年01月07日 18:42:19 rurban
-Improve id: edit: to edit-. Move search&replace js from body (defined in EditToolbar) to the toolbar.js. Support actionpages. Add tb-name argument to showPulldown
-
-Revision 1.9 2007年01月02日 13:18:26 rurban
-fix id to edit:content
-
-Revision 1.8 2006年12月22日 00:17:06 rurban
-add time to signature
-
-Revision 1.7 2006年09月06日 05:45:26 rurban
-use html tags for emphasis. workaround ^* problem
-
-Revision 1.6 2006年08月30日 05:25:40 rurban
-Handle inserting DISABLE_MARKUP_WIKIWORD and non wikiword links.
-
-Revision 1.5 2005年10月29日 14:16:17 rurban
-fix typo
-
-Revision 1.4 2005年09月29日 23:07:58 rurban
-cache toolbar
-
-Revision 1.3 2005年09月26日 06:25:50 rurban
-EditToolbar enhancements by Thomas Harding: add plugins args, properly quote control chars. added plugin method getArgumentsDescription to override the default description string
-
-Revision 1.3 2005年09月22日 13:40:00 tharding
-add modules arguments
- 
-Revision 1.2 2005年05月06日 18:43:41 rurban
-add AddTemplate EditToolbar icon
-
-Revision 1.1 2005年01月25日 15:19:09 rurban
-extract Toolbar code from editpage.php
-*/
-
 // Local Variables:
 // mode: php
 // tab-width: 8
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年05月14日 10:06:16
Revision: 6807
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=6807&view=rev
Author: vargenau
Date: 2009年05月14日 10:06:03 +0000 (2009年5月14日)
Log Message:
-----------
Add Copyright header
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年05月14日 10:01:38 UTC (rev 6806)
+++ trunk/lib/EditToolbar.php	2009年05月14日 10:06:03 UTC (rev 6807)
@@ -1,5 +1,24 @@
 <?php
 rcs_id('$Id$');
+/* Copyright 2004-2009 $ThePhpWikiProgrammingTeam
+ * Copyright 2008-2009 Marc-Etienne Vargenau, Alcatel-Lucent
+ *
+ * This file is part of PhpWiki.
+ *
+ * PhpWiki is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * PhpWiki is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with PhpWiki; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
 
 /**
 * EDIT Toolbar Initialization.
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年05月14日 10:11:45
Revision: 6808
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=6808&view=rev
Author: vargenau
Date: 2009年05月14日 10:11:35 +0000 (2009年5月14日)
Log Message:
-----------
Double square brackets for Gforge
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年05月14日 10:06:03 UTC (rev 6807)
+++ trunk/lib/EditToolbar.php	2009年05月14日 10:11:35 UTC (rev 6808)
@@ -114,7 +114,9 @@
 
 if (ENABLE_EDIT_TOOLBAR) {
 $username = $request->_user->UserName();
- if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($username))) {
+ if (defined('GFORGE') and GFORGE) {
+ $username = '[['.$username.']]';
+ } else if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($username))) {
 $username = '['.$username.']';
 }
 	 $signature = " --".$username." ".CTime();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年05月14日 13:59:38
Revision: 6810
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=6810&view=rev
Author: vargenau
Date: 2009年05月14日 13:57:28 +0000 (2009年5月14日)
Log Message:
-----------
Valid XHTML code
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年05月14日 10:21:19 UTC (rev 6809)
+++ trunk/lib/EditToolbar.php	2009年05月14日 13:57:28 UTC (rev 6810)
@@ -110,7 +110,6 @@
 global $WikiTheme, $request;
 
 $toolbar = "document.writeln(\"<div class=\\\"edit-toolbar\\\" id=\\\"toolbar\\\">\");\n";
- $accessKeyPrefix = $WikiTheme->tooltipAccessKeyPrefix();
 
 if (ENABLE_EDIT_TOOLBAR) {
 $username = $request->_user->UserName();
@@ -119,7 +118,7 @@
 } else if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($username))) {
 $username = '['.$username.']';
 }
-	 $signature = " --".$username." ".CTime();
+	 $signature = " ––".$username." ".CTime();
 $toolarray = array(
 array(
 "image"=>"ed_format_bold.png",
@@ -257,8 +256,7 @@
 (array('class'=>"toolbar",
 'src' => $sr_btn,
 'alt' =>_("Search & Replace"),
- 'title'=>_("Search & Replace")." [$accessKeyPrefix-h]",
- 'accesskey' => 'h',
+ 'title'=>_("Search & Replace"),
 'onclick'=>"replace()")));
 } else {
 $sr_html = '';
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年07月12日 02:22:37
Revision: 7012
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7012&view=rev
Author: vargenau
Date: 2009年07月12日 02:22:31 +0000 (2009年7月12日)
Log Message:
-----------
Use getUploadFilePath()
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年07月09日 09:21:02 UTC (rev 7011)
+++ trunk/lib/EditToolbar.php	2009年07月12日 02:22:31 UTC (rev 7012)
@@ -408,9 +408,7 @@
 function imagePulldown($query, $case_exact=false, $regex='auto') {
 global $WikiTheme;
 
- $image_dir = '.';
- if (defined('UPLOAD_FILE_PATH'))
- $image_dir = UPLOAD_FILE_PATH . "/$image_dir";
+ $image_dir = getUploadFilePath();
 $pd = new fileSet($image_dir, '*');
 $images = $pd->getFiles();
 unset($pd);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年10月01日 17:57:04
Revision: 7169
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7169&view=rev
Author: vargenau
Date: 2009年10月01日 17:56:54 +0000 (2009年10月01日)
Log Message:
-----------
Add horizontal line before category
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年10月01日 17:30:21 UTC (rev 7168)
+++ trunk/lib/EditToolbar.php	2009年10月01日 17:56:54 UTC (rev 7169)
@@ -304,11 +304,11 @@
 while ($p = $pages->next()) {
 		$page = $p->getName();
 if (defined('GFORGE') and GFORGE) {
- $categories[] = "['$page', '%5B%5B".$page."%5D%5D']";
+ $categories[] = "['$page', '%0A----%0A%5B%5B".$page."%5D%5D']";
 		} else if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($page))) {
-		 $categories[] = "['$page', '%5B".$page."%5D']";
+		 $categories[] = "['$page', '%0A----%0A%5B".$page."%5D']";
 		} else {
-		 $categories[] = "['$page', '$page']";
+		 $categories[] = "['$page', '%0A----%0A".$page."']";
 }
 }
 if (!$categories) return '';
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2009年10月13日 16:29:46
Revision: 7212
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7212&view=rev
Author: vargenau
Date: 2009年10月13日 16:29:32 +0000 (2009年10月13日)
Log Message:
-----------
Image button now allows also video files
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2009年10月13日 11:46:08 UTC (rev 7211)
+++ trunk/lib/EditToolbar.php	2009年10月13日 16:29:32 UTC (rev 7212)
@@ -416,8 +416,8 @@
 if (!empty($images)) {
 $image_js = '';
 foreach ($images as $image) {
- // Select only files ending in ".png", ".gif", ".jpg", ".jpeg"
- if (is_image($image)) {
+ // Select only image and video files
+ if (is_image($image) or is_video($image)) {
 $image_js .= ",['$image','{{".$image."}}']";
 }
 }
@@ -425,10 +425,10 @@
 $more_buttons = HTML::img(array('class'=>"toolbar",
 					 'id' => 'tb-images',
 'src' => $WikiTheme->getImageURL("ed_image.png"),
- 'title'=>_("AddImage"),
- 'alt'=>_("AddImage"),
+ 'title'=>_("Add Image or Video"),
+ 'alt'=>_("Add Image or Video"),
 'onclick'=>"showPulldown('".
- _("Insert Image (double-click)")
+ _("Insert Image or Video (double-click)")
 ."',[".$image_js."],'"
 ._("Insert")."','"
 ._("Close")."','tb-images')"));
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <ru...@us...> - 2010年03月30日 11:38:30
Revision: 7309
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7309&view=rev
Author: rurban
Date: 2010年03月30日 11:38:23 +0000 (2010年3月30日)
Log Message:
-----------
revert general part of r7169. multiple categories do not like ---\n
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2010年03月25日 14:50:10 UTC (rev 7308)
+++ trunk/lib/EditToolbar.php	2010年03月30日 11:38:23 UTC (rev 7309)
@@ -1,6 +1,6 @@
 <?php
 rcs_id('$Id$');
-/* Copyright 2004-2009 $ThePhpWikiProgrammingTeam
+/* Copyright 2004-2010 $ThePhpWikiProgrammingTeam
 * Copyright 2008-2009 Marc-Etienne Vargenau, Alcatel-Lucent
 *
 * This file is part of PhpWiki.
@@ -306,9 +306,9 @@
 if (defined('GFORGE') and GFORGE) {
 $categories[] = "['$page', '%0A----%0A%5B%5B".$page."%5D%5D']";
 		} else if (DISABLE_MARKUP_WIKIWORD or (!isWikiWord($page))) {
-		 $categories[] = "['$page', '%0A----%0A%5B".$page."%5D']";
+		 $categories[] = "['$page', '%0A%5B".$page."%5D']";
 		} else {
-		 $categories[] = "['$page', '%0A----%0A".$page."']";
+		 $categories[] = "['$page', '%0A".$page."']";
 }
 }
 if (!$categories) return '';
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2010年06月01日 13:58:07
Revision: 7458
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7458&view=rev
Author: vargenau
Date: 2010年06月01日 13:58:01 +0000 (2010年6月01日)
Log Message:
-----------
Present only allowed plugins
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2010年05月31日 13:23:56 UTC (rev 7457)
+++ trunk/lib/EditToolbar.php	2010年06月01日 13:58:01 UTC (rev 7458)
@@ -331,6 +331,7 @@
 // result is cached. Esp. the args are expensive
 function pluginPulldown() {
 global $WikiTheme;
+ global $AllAllowedPlugins;
 
 $plugin_dir = 'lib/plugin';
 if (defined('PHPWIKI_DIR'))
@@ -345,18 +346,20 @@
 $w = new WikiPluginLoader;
 foreach ($plugins as $plugin) {
 $pluginName = str_replace(".php", "", $plugin);
- $p = $w->getPlugin($pluginName, false); // second arg?
- // trap php files which aren't WikiPlugin~s
- if (strtolower(substr(get_parent_class($p), 0, 10)) == 'wikiplugin') {
- $plugin_args = '';
- $desc = $p->getArgumentsDescription();
- $src = array("\n",'"',"'",'|','[',']','\\');
- $replace = array('%0A','%22','%27','%7C','%5B','%5D','%5C');
- $desc = str_replace("<br />",' ',$desc->asXML());
- if ($desc)
- $plugin_args = ' '.str_replace($src, $replace, $desc);
- $toinsert = "%0A<<".$pluginName.$plugin_args.">>"; // args?
- $plugin_js .= ",['$pluginName','$toinsert']";
+ if (in_array($pluginName, $AllAllowedPlugins)) {
+ $p = $w->getPlugin($pluginName, false); // second arg?
+ // trap php files which aren't WikiPlugin~s
+ if (strtolower(substr(get_parent_class($p), 0, 10)) == 'wikiplugin') {
+ $plugin_args = '';
+ $desc = $p->getArgumentsDescription();
+ $src = array("\n",'"',"'",'|','[',']','\\');
+ $replace = array('%0A','%22','%27','%7C','%5B','%5D','%5C');
+ $desc = str_replace("<br />",' ',$desc->asXML());
+ if ($desc)
+ $plugin_args = ' '.str_replace($src, $replace, $desc);
+ $toinsert = "%0A<<".$pluginName.$plugin_args.">>"; // args?
+ $plugin_js .= ",['$pluginName','$toinsert']";
+ }
 }
 }
 $plugin_js = substr($plugin_js, 1);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2010年06月04日 14:46:15
Revision: 7465
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7465&view=rev
Author: vargenau
Date: 2010年06月04日 14:46:09 +0000 (2010年6月04日)
Log Message:
-----------
Remove "double-click", window too small
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2010年06月04日 14:45:22 UTC (rev 7464)
+++ trunk/lib/EditToolbar.php	2010年06月04日 14:46:09 UTC (rev 7465)
@@ -319,7 +319,7 @@
 'title'=>_("AddCategory"),
 'alt'=>"AddCategory", // to detect this at js
 'onclick'=>"showPulldown('".
- _("Insert Categories (double-click)")
+ _("Insert Categories")
 ."',[".join(",",$categories)."],'"
 ._("Insert")."','"
 ._("Close")."','tb-categories')"));
@@ -369,7 +369,7 @@
 'title'=>_("AddPlugin"),
 'alt'=>_("AddPlugin"),
 'onclick'=>"showPulldown('".
- _("Insert Plugin (double-click)")
+ _("Insert Plugin")
 ."',[".$plugin_js."],'"
 ._("Insert")."','"
 ._("Close")."','tb-plugins')"));
@@ -399,7 +399,7 @@
 'title'=>_("AddPageLink"),
 'alt'=>_("AddPageLink"),
 'onclick'=>"showPulldown('".
- _("Insert PageLink (double-click)")
+ _("Insert PageLink")
 ."',[".join(",",$pages)."],'"
 ._("Insert")."','"
 ._("Close")."','tb-pages')")));
@@ -431,7 +431,7 @@
 'title'=>_("Add Image or Video"),
 'alt'=>_("Add Image or Video"),
 'onclick'=>"showPulldown('".
- _("Insert Image or Video (double-click)")
+ _("Insert Image or Video")
 ."',[".$image_js."],'"
 ._("Insert")."','"
 ._("Close")."','tb-images')"));
@@ -466,7 +466,7 @@
 'title'=>_("AddTemplate"),
 'alt'=>_("AddTemplate"),
 'onclick'=>"showPulldown('".
- _("Insert Template (double-click)")
+ _("Insert Template")
 ."',[".$pages_js."],'"
 ._("Insert")."','"
 ._("Close")."','tb-templates')")));
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <ru...@us...> - 2010年09月20日 10:20:31
Revision: 7696
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=7696&view=rev
Author: rurban
Date: 2010年09月20日 10:20:25 +0000 (2010年9月20日)
Log Message:
-----------
remove duplicate global decl. This may have actually led to a bug
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2010年09月17日 11:49:14 UTC (rev 7695)
+++ trunk/lib/EditToolbar.php	2010年09月20日 10:20:25 UTC (rev 7696)
@@ -216,7 +216,6 @@
 	 }
 
 foreach ($toolarray as $tool) {
- 	global $WikiTheme;
 $image = $WikiTheme->getImageURL($tool["image"]);
 $open = $tool["open"];
 $close = $tool["close"];
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2011年10月03日 12:41:54
Revision: 8159
 http://phpwiki.svn.sourceforge.net/phpwiki/?rev=8159&view=rev
Author: vargenau
Date: 2011年10月03日 12:41:45 +0000 (2011年10月03日)
Log Message:
-----------
Same alt/title as menu
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2011年10月03日 12:40:18 UTC (rev 8158)
+++ trunk/lib/EditToolbar.php	2011年10月03日 12:41:45 UTC (rev 8159)
@@ -71,12 +71,11 @@
 $js = JavaScript('',array('src' => $WikiTheme->_findData("toolbar.js")));
 if (empty($WikiTheme->_headers_printed)) {
 $WikiTheme->addMoreHeaders($js);
- }
- else { // from an actionpage: WikiBlog, AddComment, WikiForum
+ } else { // from an actionpage: WikiBlog, AddComment, WikiForum
 printXML($js);
 printXML(JavaScript('define_f()'));
+ }
 }
- }
 
 require_once("lib/WikiPluginCached.php");
 $cache = WikiPluginCached::newCache();
@@ -314,8 +313,8 @@
 $more_buttons = HTML::img(array('class'=> "toolbar",
 'id' => 'tb-categories',
 'src' => $WikiTheme->getImageURL("ed_category.png"),
- 'title'=>_("AddCategory"),
- 'alt'=>"AddCategory", // to detect this at js
+ 'title'=>_("Insert Categories"),
+ 'alt'=>"Insert Categories", // to detect this at js
 'onclick'=>"showPulldown('".
 _("Insert Categories")
 ."',[".join(",",$categories)."],'"
@@ -364,8 +363,8 @@
 $more_buttons = HTML::img(array('class'=>"toolbar",
 'id' => 'tb-plugins',
 'src' => $WikiTheme->getImageURL("ed_plugins.png"),
- 'title'=>_("AddPlugin"),
- 'alt'=>_("AddPlugin"),
+ 'title'=>_("Insert Plugin"),
+ 'alt'=>_("Insert Plugin"),
 'onclick'=>"showPulldown('".
 _("Insert Plugin")
 ."',[".$plugin_js."],'"
@@ -394,8 +393,8 @@
 return HTML("\n", HTML::img(array('class'=>"toolbar",
 'id' => 'tb-pages',
 'src' => $WikiTheme->getImageURL("ed_pages.png"),
- 'title'=>_("AddPageLink"),
- 'alt'=>_("AddPageLink"),
+ 'title'=>_("Insert PageLink"),
+ 'alt'=>_("Insert PageLink"),
 'onclick'=>"showPulldown('".
 _("Insert PageLink")
 ."',[".join(",",$pages)."],'"
@@ -432,8 +431,8 @@
 $more_buttons = HTML::img(array('class'=>"toolbar",
 'id' => 'tb-images',
 'src' => $WikiTheme->getImageURL("ed_image.png"),
- 'title'=>_("Add Image or Video"),
- 'alt'=>_("Add Image or Video"),
+ 'title'=>_("Insert Image or Video"),
+ 'alt'=>_("Insert Image or Video"),
 'onclick'=>"showPulldown('".
 _("Insert Image or Video")
 ."',[".$image_js."],'"
@@ -467,8 +466,8 @@
 (array('class'=>"toolbar",
 'id' => 'tb-templates',
 'src' => $WikiTheme->getImageURL("ed_template.png"),
- 'title'=>_("AddTemplate"),
- 'alt'=>_("AddTemplate"),
+ 'title'=>_("Insert Template"),
+ 'alt'=>_("Insert Template"),
 'onclick'=>"showPulldown('".
 _("Insert Template")
 ."',[".$pages_js."],'"
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年07月30日 15:50:05
Revision: 9032
 http://sourceforge.net/p/phpwiki/code/9032
Author: vargenau
Date: 2014年07月30日 15:50:02 +0000 (2014年7月30日)
Log Message:
-----------
Use private functions
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年07月30日 15:04:20 UTC (rev 9031)
+++ trunk/lib/EditToolbar.php	2014年07月30日 15:50:02 UTC (rev 9032)
@@ -32,8 +32,7 @@
 
 class EditToolbar
 {
-
- function EditToolbar()
+ function __construct()
 {
 global $WikiTheme;
 
@@ -104,12 +103,12 @@
 }
 }
 
- function getTokens()
+ public function getTokens()
 {
 return $this->tokens;
 }
 
- function _generate()
+ private function _generate()
 {
 global $WikiTheme, $request;
 
@@ -293,7 +292,7 @@
 }
 
 //result is cached
- function categoriesPulldown()
+ private function categoriesPulldown()
 {
 global $WikiTheme;
 
@@ -331,7 +330,7 @@
 }
 
 // result is cached. Esp. the args are expensive
- function pluginPulldown()
+ private function pluginPulldown()
 {
 global $WikiTheme;
 global $AllAllowedPlugins;
@@ -382,7 +381,7 @@
 }
 
 // result is cached. Esp. the args are expensive
- function pagesPulldown($query, $case_exact = false, $regex = 'auto')
+ private function pagesPulldown($query, $case_exact = false, $regex = 'auto')
 {
 require_once 'lib/TextSearchQuery.php';
 $dbi =& $GLOBALS['request']->_dbi;
@@ -412,7 +411,7 @@
 }
 
 // result is cached. Esp. the args are expensive
- function imagePulldown($query, $case_exact = false, $regex = 'auto')
+ private function imagePulldown($query, $case_exact = false, $regex = 'auto')
 {
 global $WikiTheme;
 
@@ -453,7 +452,7 @@
 
 // result is cached. Esp. the args are expensive
 // FIXME!
- function templatePulldown($query, $case_exact = false, $regex = 'auto')
+ private function templatePulldown($query, $case_exact = false, $regex = 'auto')
 {
 global $request;
 require_once 'lib/TextSearchQuery.php';
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年07月30日 16:02:17
Revision: 9033
 http://sourceforge.net/p/phpwiki/code/9033
Author: vargenau
Date: 2014年07月30日 16:02:08 +0000 (2014年7月30日)
Log Message:
-----------
Remove unused
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年07月30日 15:50:02 UTC (rev 9032)
+++ trunk/lib/EditToolbar.php	2014年07月30日 16:02:08 UTC (rev 9033)
@@ -279,7 +279,7 @@
 
 // Button to add images, display in extra window as popup and insert
 if (TOOLBAR_IMAGE_PULLDOWN)
- $sr_html = HTML($sr_html, $this->imagePulldown(TOOLBAR_IMAGE_PULLDOWN));
+ $sr_html = HTML($sr_html, $this->imagePulldown());
 
 // don't use document.write for replace, otherwise self.opener is not defined.
 $toolbar_end = "document.writeln(\"</div>\");";
@@ -411,9 +411,9 @@
 }
 
 // result is cached. Esp. the args are expensive
- private function imagePulldown($query, $case_exact = false, $regex = 'auto')
+ private function imagePulldown()
 {
- global $WikiTheme;
+ global $WikiTheme, $request;
 
 $image_dir = getUploadFilePath();
 $pd = new fileSet($image_dir, '*');
@@ -458,7 +458,6 @@
 require_once 'lib/TextSearchQuery.php';
 $dbi =& $request->_dbi;
 $page_iter = $dbi->titleSearch(new TextSearchQuery($query, $case_exact, $regex));
- $count = 0;
 if ($page_iter->count()) {
 global $WikiTheme;
 $pages_js = '';
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年07月30日 16:09:31
Revision: 9034
 http://sourceforge.net/p/phpwiki/code/9034
Author: vargenau
Date: 2014年07月30日 16:09:24 +0000 (2014年7月30日)
Log Message:
-----------
Remove "This is the table summary"
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年07月30日 16:02:08 UTC (rev 9033)
+++ trunk/lib/EditToolbar.php	2014年07月30日 16:09:24 UTC (rev 9034)
@@ -173,7 +173,7 @@
 "sample" => "",
 "title" => _("Horizontal line")),
 array("image" => "ed_table.png",
- "open" => "\\n{| class=\"bordered\"\\n|+ This is the table caption\\n|= This is the table summary\\n|-\\n! Header A !! Header B !! Header C\\n|-\\n| Cell A1 || Cell B1 || Cell C1\\n|-\\n| Cell A2 || Cell B2 || Cell C2\\n|-\\n| Cell A3 || Cell B3 || Cell C3\\n|}\\n",
+ "open" => "\\n{| class=\"bordered\"\\n|+ This is the table caption\\n|-\\n! Header A !! Header B !! Header C\\n|-\\n| Cell A1 || Cell B1 || Cell C1\\n|-\\n| Cell A2 || Cell B2 || Cell C2\\n|-\\n| Cell A3 || Cell B3 || Cell C3\\n|}\\n",
 "close" => "",
 "sample" => "",
 "title" => _("Sample table")),
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年07月31日 09:03:50
Revision: 9036
 http://sourceforge.net/p/phpwiki/code/9036
Author: vargenau
Date: 2014年07月31日 09:03:47 +0000 (2014年7月31日)
Log Message:
-----------
Initialize data_path
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年07月31日 08:45:40 UTC (rev 9035)
+++ trunk/lib/EditToolbar.php	2014年07月31日 09:03:47 UTC (rev 9036)
@@ -69,10 +69,13 @@
 }
 
 if (ENABLE_EDIT_TOOLBAR) {
+ $init = JavaScript("var data_path = '" . javascript_quote_string(DATA_PATH) . "';\n");
 $js = JavaScript('', array('src' => $WikiTheme->_findData("toolbar.js")));
 if (empty($WikiTheme->_headers_printed)) {
+ $WikiTheme->addMoreHeaders($init);
 $WikiTheme->addMoreHeaders($js);
 } else { // from an actionpage: WikiBlog, AddComment, WikiForum
+ printXML($init);
 printXML($js);
 printXML(JavaScript('define_f()'));
 }
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年10月15日 12:19:34
Revision: 9263
 http://sourceforge.net/p/phpwiki/code/9263
Author: vargenau
Date: 2014年10月15日 12:19:31 +0000 (2014年10月15日)
Log Message:
-----------
Regenerate toolbar cache when a new image was uploaded
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年10月15日 09:10:49 UTC (rev 9262)
+++ trunk/lib/EditToolbar.php	2014年10月15日 12:19:31 UTC (rev 9263)
@@ -93,6 +93,9 @@
 if (TOOLBAR_TEMPLATE_PULLDOWN) {
 $key .= "+templates_" . $dbi->getTimestamp();
 }
+ if (TOOLBAR_IMAGE_PULLDOWN) {
+ $key .= "+images_" . filemtime(getUploadFilePath());
+ }
 $id = $cache->generateId($key);
 $content = $cache->get($id, 'toolbarcache');
 
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年10月15日 12:36:34
Revision: 9264
 http://sourceforge.net/p/phpwiki/code/9264
Author: vargenau
Date: 2014年10月15日 12:36:30 +0000 (2014年10月15日)
Log Message:
-----------
Update comment
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年10月15日 12:19:31 UTC (rev 9263)
+++ trunk/lib/EditToolbar.php	2014年10月15日 12:36:30 UTC (rev 9264)
@@ -84,7 +84,7 @@
 require_once 'lib/WikiPluginCached.php';
 $cache = WikiPluginCached::newCache();
 $dbi = $GLOBALS['request']->getDbh();
- // regenerate if number of pages changes (categories, pages, templates)
+ // regenerate if number of pages changes (categories, pages, templates, images uploaded)
 $key = $dbi->numPages();
 $key .= '+categories+plugin' . (isBrowserSafari() ? '+safari' : '');
 if (TOOLBAR_PAGELINK_PULLDOWN) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年10月15日 16:14:06
Revision: 9267
 http://sourceforge.net/p/phpwiki/code/9267
Author: vargenau
Date: 2014年10月15日 16:14:03 +0000 (2014年10月15日)
Log Message:
-----------
Check getUploadFilePath exists to avoid warning
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年10月15日 14:48:34 UTC (rev 9266)
+++ trunk/lib/EditToolbar.php	2014年10月15日 16:14:03 UTC (rev 9267)
@@ -94,7 +94,9 @@
 $key .= "+templates_" . $dbi->getTimestamp();
 }
 if (TOOLBAR_IMAGE_PULLDOWN) {
- $key .= "+images_" . filemtime(getUploadFilePath());
+ if (file_exists(getUploadFilePath())) {
+ $key .= "+images_" . filemtime(getUploadFilePath());
+ }
 }
 $id = $cache->generateId($key);
 $content = $cache->get($id, 'toolbarcache');
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
From: <var...@us...> - 2014年10月16日 10:34:33
Revision: 9274
 http://sourceforge.net/p/phpwiki/code/9274
Author: vargenau
Date: 2014年10月16日 10:34:31 +0000 (2014年10月16日)
Log Message:
-----------
Use imageOrVideoSet
Modified Paths:
--------------
 trunk/lib/EditToolbar.php
Modified: trunk/lib/EditToolbar.php
===================================================================
--- trunk/lib/EditToolbar.php	2014年10月16日 10:18:36 UTC (rev 9273)
+++ trunk/lib/EditToolbar.php	2014年10月16日 10:34:31 UTC (rev 9274)
@@ -424,12 +424,12 @@
 global $WikiTheme, $request;
 
 $image_dir = getUploadFilePath();
- $pd = new fileSet($image_dir, '*');
+ $pd = new imageOrVideoSet($image_dir, '*');
 $images = $pd->getFiles();
 unset($pd);
 if (UPLOAD_USERDIR) {
 $image_dir .= "/" . $request->_user->_userid;
- $pd = new fileSet($image_dir, '*');
+ $pd = new imageOrVideoSet($image_dir, '*');
 $images = array_merge($images, $pd->getFiles());
 unset($pd);
 }
@@ -437,10 +437,7 @@
 if (!empty($images)) {
 $image_js = '';
 foreach ($images as $image) {
- // Select only image and video files
- if (is_image($image) or is_video($image)) {
- $image_js .= ",['$image','{{" . $image . "}}']";
- }
+ $image_js .= ",['$image','{{" . $image . "}}']";
 }
 $image_js = substr($image_js, 1);
 $more_buttons = HTML::img(array('class' => "toolbar",
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.
Thanks for helping keep SourceForge clean.
X





Briefly describe the problem (required):
Upload screenshot of ad (required):
Select a file, or drag & drop file here.
Screenshot instructions:

Click URL instructions:
Right-click on the ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)

More information about our ad policies

Ad destination/click URL:

AltStyle によって変換されたページ (->オリジナル) /