|
Cookbook /
TableEditSummary: Interactive table editor
Version: 0.2 (17 December 2006)
Prerequisites: Pmwiki 2.1.26
Status: first version
Maintainer: PRZ
Questions answered by this recipeHow to edit tables more easily. DescriptionInteractive table editor. Installation notesDownload TableEdit.zipΔ The files expands in the appropriate directories from the wiki root directory As with other addons, to use the cookbook:
include_once("cookbook/tabledit.php");
To include the GUIedit bar set in the config file: If you wish to use the larger images of Guiedit32, just set *before* the cookbook inclusion: $GUIButtonDirUrlFmt = 'The autoinsert version works for 'out of the box' pmwiki version, but for older skins, where there is only one form, if the button inserts the table, but does not autostart the table edit screen, try: $TEEditFormNum = 0;
include_once("cookbook/tabledit.php");
This is related to the fact that on present skins the edit screen has two forms, the first being the top search, the second being the edit itself. You may also modify that parameter for others skins. 0 is the 1rst form, 1 is the 2nd form, 2 is the 3rd form, etc. you can see that on the javascript code at the bottom of your browser when moving the mouse on the insert table button. If you wish to use the (highly recommended) SectionEdit recipe, the tabledit inclusion should be set *before* the sectionedit. This is related to the fact that both addons are competing to modify the directive 'include', and the tabledit takes the presence of 'sectionedit' into account when set first (due to the fact that a directive can only be modified one time). UsageFor inserting table in edit mode, you should first click in the window precisely where you want to set the table. The editor is only for 'advanced tables', 'simple tables' having no interest for an automated interface. It is also much more flexible. The tables inside included pages are not editable. They are simply ignored. You still can modify by 'hand editing' the table and cells parameters. The parameters unknown from the addon are maintained through the edition process. If the GuiEdit bar is activated, an 'insert table' button is automatically added at the end of the bar. It creates and edit a 3 cols, 2 rows table. to remove the sign "(Table edit ↓)", write the directive (:notabledit:) and the sign shall no longer be displayed after the directive Site example : ![]() Edit table link automatically created
![]() Edit table screen
Release Notes
TranslationThe cookbook is ready for translation, and specific words have been entered in the XLPageCookbookTemplate. If your wiki is not in english, look if the page XLPageCookbook exists in your language, install it and reference it in the config.php file. If not yet existing in your language, the translation strings are listed in the PmWiki.XLPageCookbookTemplate in the pmwiki site. So help yourself and please also modify the original pmwiki translation page. CommentsIt would also be a good idea to have a simple table to advanced table convertor. If someone fluent in regular expression is volunteering, the result can be incorporated in the cookbook. In the design of this cookbook, some ideas were kept from 'sectionedit' cookbook and also from 'minimage'. Dan T. -- Sep 21 2008
D. Flores - 19-May 2008 Davide Andrea April 11th 2008. Dey - 11th January 2007 Greeting to all of you too! This is most probably true considering the way this addon works, but I don't see any simple solution. Having two people on the same table shall normally be not very frequent. For the rest of the page, it is recovered just before table modifications are saved, so normally there shall be no harm when people are working simultaneously on the same page, except if this is on the same table.PRZ Just tried 1st release and nothing happens - No "edit table" button/link appeared. Is there any special settings needed besides the "include"? Yes, the button is part of the GuiEdit bar, so the bar shall be activated to get the button PRZ Is there a way to stop the "(Table edit ↓)" links from appearing above all tables? Yes, use the directive (:notabledit:) - sorry, that was not documented I tried also inserting a table with the new "insert table" button, but still didn't see any interactive editing after save... Avi 17-Dec-2006
There are in fact different problems
Anyway, please report and if you still have problem precise your pmwiki and skin version, along browser type used. I am using FF 2.0 (but tried also on IE6). using latest beta of pmwiki. trying 2 skins pmwiki (the default and newest) and monobook (but monobook is a little older). When I press the "Insert table" button I get the text inserted but no form started. When I try to paste "?action=tabledit&s=0" at the addressbar I get the form with an empty table, so probably the form should have been started - but it is not. I saw it works on your sandbox. But couldn't make it work on mine... Maybe one of the other add-ons I use blocks it ? Avi 18-Dec-2006
Have you tested it as told above with :
$TEEditFormNum = 0;
include_once("cookbook/tabledit.php");
If it still doesn't work, try it the heavy way (giving a name to the form):
$InputTags['e_form']= array(
':html' => "<form name='edform' action='{\$PageUrl}?action=edit' method='post'><input
type='hidden' name='action' value='edit' /><input
type='hidden' name='n' value='{\$FullName}' /><input
type='hidden' name='basetime' value='\$EditBaseTime' />");
$TEEditFormNum = "'edform'";
include_once("cookbook/tabledit.php");
the instruction to post the edit form is in javascript: Updated version
NickBell 4th April 2007 :: Hi, firstly thanks for this nice plugin. Unfortunatelly the link doesn't link with the new tabledit.0.3.php. Then I have another question: is it possible to make the edit-boxes for the tables bigger than three lines? -- Profiles April 30, 2007, at 11:38 AM Ok, version corrected in the example page - Nothing standard is defined for increased height of edit boxes, try modifying the line 142: $htarea = 3; with a larger value than three ('htarea' is for 'area height' in my personal naming system...) PRZ May 09, 2007, at 03:34 PM ::Hi Looks like a great add in...I am having a small problem. I installed the Edit Not Saved Recipe that conflicted with the guiedit.php. When you clicked on a gui button, it thought you were trying to exit and you got the message. To correct it, you added the following to one of the lines in guiedit.php This line $tag = "<img src='{$m[1]}' $title style='border:0px;' />";
became this $tag = "<img src='{$m[1]}' $title style='border:0px;' onclick='needToConfirm = false;' />"; I looked for a similar line in tabledit.php and didn't find one...any ideas? Thanks DaveF December 10, 2007 See AlsoContributors
User notes?: If you use, used or reviewed this recipe, you can add your name. The following format is recognized:
* (+) Optional positive comment. Name, date * (-) Optional negative comment. Name, date These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki. |