[pmwiki-users] History Snapshots?
I know this question has come up a few times in the past, but I'm unsure of the current state of things. Is there any convenient way to get some snapshots of how a page looked at different points in time? We have a page with tables on it that has undergone numerous edits, and one of my users would like to be able to see what it looked like a few months ago. Trying to visualize it from the history diffs is next to impossible. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Extending file name characters
Patrick R. Michaud wrote: On Sun, Sep 07, 2008 at 10:49:14AM -0500, Patrick R. Michaud wrote: On Sun, Sep 07, 2008 at 08:58:39PM +1300, Simon wrote: Thankyou very much, I presume that this applies to + as well. Since the URL is generated by PmWiki would it be possible to change PmWiki so that it encodes the URL in this way Does PmWiki not already do this? Is there a page I could look at that contains such a link? Oh of course PmWiki doesn't do this -- it knows how to do the encodings for page names, but not for links (because sometimes people need to be able to put '+' and '#' in urls that *aren't* part of the path or converted to %2b/%23). I've often wished for a way to explicitly ask for a particular character in a link to be % encoded so that it forms a valid URL. Something like a '\' escape might work so that: [[home/foo#zot]] is a link to the zot anchor in the foo page of the home group while [[home/foo\#zot]] would be a link to the foo#zot page in the home group. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Extending file name characters
Patrick R. Michaud wrote: On Thu, Nov 13, 2008 at 07:34:15PM -0500, Stirling Westrup wrote: I've often wished for a way to explicitly ask for a particular character in a link to be % encoded so that it forms a valid URL. Something like a '\' escape might work so that: [[home/foo#zot]] is a link to the zot anchor in the foo page of the home group while [[home/foo\#zot]] would be a link to the foo#zot page in the home group. I have other expectations for the backslash -- most wiki markup languages are starting to use it to mean don't process what follows as markup. So we'd need to use something else -- nothing immediately comes to my mind, though. I feared that the backslash would already be taken. The only other things I can think of are %, so we'd have [[home/foo%#zot]], but that might interfere with styles, or some sort of quote convention using begin-escaped and end-escaped tokens... ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Pagelist question
Jan Erik Moström wrote: I'm trying to implement some kind of blog feature (yes, I know there are several suggestions for how to do this ... see this as an exercise in learning more about pmwiki). I'm trying to keep things as simple as possible and base everything on the pagelist command, on thing I'm trying to implement is future post. In other words I want to be able to write and post an entry that shouldn't appear until some future day. I've got one entry/page and they all have the format MMDDHHMMSS. My idea was to let pagelist only list the pages that have names that are less or equal that the current date/time. I've been looking at the pagelist page but can't see any option that would allow me to do this kind of listing. Then I tried to figure out if I could make a list format that would do this, but looking at ConditionalMarkup I'm unsure on how I should do. I would be grateful for a hint on how to solve thise The standard way would be to use the if= parameter of pagelist, coupled with a date test. Something like this: (:pagelist group=BLOG if=date ..{(ftime %F)} {=$Name} :) That should list all the pages in the blog group, which when interpreted as a date, are before the current date. Hmm. Come to think of it, I'm not sure that date will accept both date AND time. You may need to truncate the value of {=$Name} to get the above to work. Maybe we need (:if time ... :) or (:if datetime ... :) conditionals as well? They shouldn't be hard to write. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] edit templates: auto update dates?
Henrik wrote: Regarding http://www.pmwiki.org/wiki/Cookbook/EditTemplates Is it possible to automatically update dates, to that the imported text contains the current date (as text, not as a variable). So for example if creating a page today, I would like the title, as imported from the template, to have in the edit textbox Farmers' Market news for April 10, 2008 Where the date is written in as clear text from the template. When I started using edit templates, I found the same need for having things evaluated at edit time. I came up with this simple recipe. It assumes that the $EditTemplatesFmt is set like this: $EditTemplatesFmt = '{$SiteGroup}.{$Group}-Template'; But it would be fairly easy to fix it. # # Edit template vars and expressions. # # Use $Foo instead of {$Foo} and # (func ...) instead of {(func ...)} # # to have them evaluated before edit. # $pn=MakePageName($pagename,$pagename); if( !preg_match(/^$SiteGroup\..*-Template$/,$pn) ) $ROEPatterns = array ( '/(\\*|!?[-\\w.\\/\\x80-\\xff]*)(\\$:?\\w+)/e' = PRR(PVSE(PageVar(\$pagename, '$2', '$1'))) , '/(\\(\\w+\\b.*?\\))/e' = MarkupExpression(\$pagename, PSS('$1')) ); Once you have this in your local/config.php, all you need to do is write a template with contents like this: Farmers' Market news for (ftime %B %d, %Y ) ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] markup question
noskule wrote: hi list could someone please take a look at this markup. I cant get it to work. It should rpoduce a fieldset: If what you want is markup for fieldset and legend, it already exists: http://www.pmwiki.org/wiki/Cookbook/FormExtensions ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] MySQL and Notify?
I've been asked to put up a simple volunteering form on a PmWiki website. They would like the results from the form to be stored in a MySQL database, and a copy of the data emailed to the person in charge of volunteers. I know of recipes to store form data in a database, and ones to mail results to someone, but what's the best way to do both? Use a database recipe and some variation of Notify perhaps? Will they even play nice together? Any suggestions would be helpful, although I should mention that I'm not interested in using Zap. The learning curve for getting MySQL working is already steep enough (I've never used it before), so I don't want to add to the difficulty. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Borrowing title from another page
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Sameer Kumar wrote: I have two groups: 'Projects' and 'Projecttext'. For each page in Projects, there is a corresponding page in Projecttext. Each page in Projects group has a specified (:title:). I would like the pages in Projecttext to inherit the Title of the corresponding page in the Projects group. I don't think there is any non-recipe approach that will work. The title for a page is saved in that pages' meta-information when the page is saved. I think you would need to write a recipe that overrode the default title handling in order to get the effect you want. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.8 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkeY96IACgkQ5dZZEoPlyIVIWwCghUfTdm6cVVBKuD2rqlF1GrGq qMEAn0ati/lqP/9msIJZPQRR8N6z5s9+ =Upvu -END PGP SIGNATURE- ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Small problem with changed default page
Anke Wehner wrote: Hello. I have the following in my config.php tp change the default name: $DefaultName = 'Main'; $PagePathFmt = array('$Group.$1', '$1.$DefaultName'); This works on links inside the wiki - [[Group/]] links to Group.Main and all - but one problem I noticed that when I change the url per hand, say, removing the page name, so I have ...wiki.php/Group , it looks for Group.Group rather than Group.Main. Is there something obvious I missed? (I'm using .beta65) Alas, that is PmWiki's normal behaviour. $PagePathFmt is a /search/ path that tells PmWiki where to look for an under-specified page (ie, Group or Name part missing). It has no effect if no page is found at all. In that case PmWiki is hardwired to call the page $Group.$Group. There has been some talk lately of a general mechanism to give better control over this, but in the meantime one has to add some code to config.php if they want to override the default behaviour. Something like this should work (note that I haven't tested this): $DefaultName = 'Main'; if( strpos($pagename, '.') === FALSE ) $pagename .= .$DefaultName; This essentially just tacks on a '.Main' to the end of any pagename that doesn't have a dot in it. There may be edge cases where one needs more complicated processing (such as, what if the input name was '.Foo'?) ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Include with a Regular Expression
Eric Celeste wrote: I'd like to create a recent changes page that only includes a subset of pages in a given group. For example, a set of pages in the group start with the name Nico- and another set start with Hcm- and I'd like to have two separate RecentChanges pages so that interested parties need only see those changes. I am wondering if there is any version of the (:include:) directive that understands regular expressions? I didn't see a cookbook to this effect, but I imagine someone may have run into a need like this before. If I could just include lines that match a certain pattern, then the task of building a limited RecentChanges page would be pretty simple. Of course, maybe there is a better way of approaching the problem altogether! Its not clear how you are planning to use (:include...:) directives to create the RecentChanges pages you want, but you can probably do it by using a (:pagelist...:) command (which can accept wildcards or, with a bit of work, regular expressions) and have the (:include:) directive appear in the display template for the pagelist. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Include with a Regular Expression
Eric Celeste wrote: I don't think I can use pagelist since it has no concept of which pages have recently changed and which have not. I was going to use something like... (:include RecentChagnes regex=Nico-:) (oversimplified and nonexistent, but this is just an example) to pull only lines from the RecentChanges page that are pertinent in order to create a new page with just that subset of the recent changes. There really isn't a good way to extract subsections of a page the way you are thinking. Even if there was, you'd need a much more complex regex as you'd want to end up grabbing the entire line containing a given reference, not just the matching text, and you'd need to ensure you didn't include a change to the wrong page, just because the summary of the change mentioned some other page. What most folks do in circumstances like this is to put some code in their config.php file to change which pages get change-summaries written to. Something like this: $page = PageVar($pagename, '$FullName'); if( preg_match('/^SomeGroup.Nico-/', $page) ) $RecentChangesFmt['SomeGroup.RecentChanges-Nico'] = '* [[{$Group}.{$Name}]] . . . $CurrentTime [=$ChangeSummary=]'; Then you simply use the contents of RecentChanges-Nico when you want those specific pages. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] 'Draft' mode?
Steven Benmosh wrote: There is a nice feature in wordpress, which is draft mode - it lets you work on the page until you are ready, and then you select publish to expose it to the world, or private which does something else, not sure what... PmWiki has this feature too, but its new and not yet well-documented. You can start reading about it here: http://www.pmwiki.org/wiki/PmWiki/Drafts ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] QuickReplace recipe
Jan Hegewald wrote: Hello all, I use the QuickReplace recipe (by Stirling Westrup) everywhere in my pmwiki. Unfortunately it seems to also substitute text in URLs: http://java.sun.com/docs/hotspot/HotSpotFAQ.html will become http://java.sun.com/docs/hotspot/HotSpot%9D%9D47%9D%9D.html Is there some way to tell QuickReplace not to modify URLs at all? QuickReplace is intended to work by having some markup around all replacements, and only those get replaced. It looks like you've set it up so that all occurrences of 'FAQ' are being replaced with something. Is this right? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] (:template none:) ?
I'm currently trying to write a pagelist format that can handle 0, 1 or several hits being returned, but I'm having trouble with the case of no matches. I would like to display a message in that case, but it looks like the entire contents of the format is ignored if there are no matches. Ideally I'd like something like a (:template none:) that only gets output when the list is empty. That way one could do this: [[#listfmt]] (:template first:) ||'''Name''' ||'''Rank''' || (:template each:) ||{=$:Name} ||{=$:Rank} || (:template last:) There were {$$PageCount} matching records. (:template none:) No records matched your query. [[#listfmtend]] ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Condition Names.
DaveG wrote: (:if permit ...:) That's actually a really good suggestion, but since, as Pm pointed out, I can just do (:if equal {$Action} ... :), we may as well use (:if action ...:) for the permissions test. I'm assuming that what follows would be an adequate definition for (:if action ...:), unless I'm missing something. # Test to see if an action is permitted $Conditions['action'] = 'NoCache(CondAction($pagename, $condparm))'; function CondAction($pagename, $condparm) { global $HandleAuth; @list($level, $pn) = explode(' ', $condparm, 2); $level = array_key_exists($level,$HandleAuth) ? $HandleAuth[$level] : $level; $pn = ($pn '') ? MakePageName($pagename, $pn) : $pagename; return (boolean)RetrieveAuthPage($pn, $level, false, READPAGE_CURRENT); } ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Condition Names.
Patrick R. Michaud wrote: The normal way to test for the current action is (:if equal {$Action} ... :) For some reason, that had never occurred to me... ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Dumb Question: Access Classes without AuthUser?
Patrick R. Michaud wrote: On Tue, Nov 06, 2007 at 02:39:38AM -0500, Stirling Westrup wrote: I've got a PmWiki website that I also use as a personal information manager. Right now I'm not using AuthUser, since there's only two classes of access: public and private. Now, I've been thinking of putting up some content that I want to limit to a few close friends. Rather than going the full AuthUser route, I'd like to just introduce some passwords that would give varying degrees of access to the internals. As such, I would have group passwords, but no usernames. Such a scheme might look like: $DefaultPasswords['@personal'] = crypt(JustMePassword); $DefaultPasswords['@intimates'] = crypt(VeryCloseFriendsPassword); $DefaultPasswords['@friends'] = crypt(FriendsPassword); $DefaultPasswords['@prerelease']= crypt(AlmostPublicPassword); Yes, except that $DefaultPasswords is normally tied to actions and not to accounts... I think you can get what you want by doing something like: if (@$_POST['authpw']) { $AuthGroupPasswords = array( '@personal' = crypt(JustMePassword), '@intimates' = crypt(VeryCloseFriendsPassword), '@friends' = crypt(FriendsPassword), '@prerelease' = crypt(AlmostPublicPassword)); # loop through all of the group/password combinations, setting # $authlist[group] to 1 for any matches foreach($AuthGroupPasswords as $g = $pw) { if (crypt($_POST['authpw'], $pw) == $pw) $authlist[$g] = 1; } # if we had any matches, then authorize the group for this session. if ($authlist) SessionAuth($pagename, array('authlist'=$authlist)); } I haven't tested the above, but it should be fairly close. It doesn't work as-is. I tried a few things, but no dice. I guess I'll have to wait until I have time to puzzle through the PmWikiAuth function to figure out whats gone wrong. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Triad and NewPageBoxPlus
I'm using NewPageBoxPlus with the latest Triad skin, and I've found that the page name set with (:newpagebox value=Page Name Here:) doesn't clear when I click in the box. Does anyone else have that problem, or is it something about my setup? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Condition Names.
I've just checked, and there is currently no (:if action:) test in the core to see if one has permission to perform a given action. See a recent discussion here with PM about how (:if auth:) doesn't quite do that, as it ignores the $HandleAuth array. It shouldn't be too hard to add such a test, but what should it be called? The reason I ask is that I already have a custom (:if action:) test which instead checks to see what the current value of $action is. They can't both have the same name, so what should I call them? I'm currently thinking: (:if authact ...:) to see if an action is authorized (:if action ...:) to see what the current action is. What do folks think? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] basepage and PTVs not working.
I have a problem with using PTVs relative to a basepage, on a site I'm working on. I can't point to the site under development, but I managed to reproduce it on a different site hosted by the same farm. All attempts to duplicate the problem on PmWiki have failed, and I can't figure out what's different. Here's the PmWiki test page that works fine: http://www.pmwiki.org/wiki/Test/BaseA It correctly includes Test.BaseB using a basepage of Test.BaseC. When I try the exact same thing on a clean install in my farm, it doesn't work: http://sti.pooq.com/patterns/Test/BaseA The local/config for this latter site is very simple: ?php if (!defined('PmWiki')) exit(); ini_set('display_errors', 1); $EnableDiag=1; $EnablePathInfo = 1; $PubDirUrl = http://sti.pooq.com/patterns/pub;; $FarmPubDirUrl = http://sti.pooq.com/wikipub;; $ScriptUrl = http://sti.pooq.com/patterns;; $DefaultPasswords['admin'] = crypt('quick'); Does anyone have any ideas what could be going wrong? My farmconfig.php file is completely empty, so its nothing that I'm doing there. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] basepage and PTVs not working.
Patrick R. Michaud wrote: You may need to set $EnableRelativePageVars=1; . This is not yet the default, although it's likely to become the default before 2.2.0 is released. D'Oh! I should have thought of that! I've gotten so used to having them turned on, I forgot they weren't the default. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Dumb Question: Access Classes without AuthUser?
I've got a PmWiki website that I also use as a personal information manager. Right now I'm not using AuthUser, since there's only two classes of access: public and private. Now, I've been thinking of putting up some content that I want to limit to a few close friends. Rather than going the full AuthUser route, I'd like to just introduce some passwords that would give varying degrees of access to the internals. As such, I would have group passwords, but no usernames. Such a scheme might look like: $DefaultPasswords['@personal'] = crypt(JustMePassword); $DefaultPasswords['@intimates'] = crypt(VeryCloseFriendsPassword); $DefaultPasswords['@friends'] = crypt(FriendsPassword); $DefaultPasswords['@prerelease']= crypt(AlmostPublicPassword); This would allow me to set @personal, etc passwords on groups, and be able to change the passwords without having to edit the group attributes. Now, of course the above won't work, but I hope it illustrates what I'd like. I can do something vaguely like it by installing AuthUser and doing: $AuthUser['personal'] = crypt(JustMePassword); $AuthUser['intimates'] = crypt(VeryCloseFriendsPassword); $AuthUser['friends'] = crypt(FriendsPassword); $AuthUser['prerelease']= crypt(AlmostPublicPassword); $AuthUser['@personal'] = 'personal'; $AuthUser['@intimates'] = 'intimates'; $AuthUser['@friends'] = 'friends'; $AuthUser['@prerelease']= 'prerelease'; But this requires everyone to log in with both a username and a password, and I'd prefer only the password. Anyone have any suggestions as to how I might do this? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Trouble with latest Triad version.
I just downloaded and installed the latest version of Triad, and ran across a problem. It calls include_once on a file called 'searchbox2.php', but its not included in the .zip file. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Multiple Languages, RSS and Categories.
Patrick R. Michaud wrote: On Sat, Oct 27, 2007 at 02:06:06PM -0400, Stirling Westrup wrote: I am currently working on a recipe for a multi-lingual blog, and I'm having trouble figuring out how I should implement tags so that RSS feeds work. With a single blog, one often just sticks [[!foo]] into a blog page, and its automagically picked up by the RSS feed and a categoryfoo/category gets added. My problem is that I want the English RSS feed to only link to English articles using English category names, and the French Blog should be similarly set up. Now, I can't just mix them altogether into one Category group, because some labels (like 'blog') are the same in French and English, and I don't want someone looking up Category/Blog to get a mix of languages. I've been thinking of setting up individual Category-like groups (probably 'Tags' for English and 'Balises' for French) and creating links like [[Tags.thing]] and [[Balises.chose]]. This will keep my tags in separate namespaces, but how do I get the separate RSS feeds for the two blogs to each grab the right category pages? RSS feed of the pages in the Tags.Thing category, most recently changed pages returned first: .../pmwiki.php?action=rsslink=Tags.Thingorder=-mtime RSS feed of pages in the Balises.Chose category, most recently changed pages returned first: .../pmwiki.php?action=rsslink=Balises.Choseorder=-mtime Ah, no, that's not what I meant. I have two blog groups, EnBlog containing the pages of an English blog and FrBlog containing pages of a French blog. I need .../pmwiki.php/EnBlog/RecentChanges?action=rss to somehow know to fill in the category.../category tags in the RSS feed using links to the Tags group as category indicators. Similarly, I want .../pmwiki.php/FrBlog/RecentChanges?action=rss to fill in the category.../category values using links from the FrBlog pages to the Balises group. Is this possible, or have I fundamentally misunderstood how PmWiki generates category tags inside RSS feeds? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Multiple Languages, RSS and Categories.
I am currently working on a recipe for a multi-lingual blog, and I'm having trouble figuring out how I should implement tags so that RSS feeds work. With a single blog, one often just sticks [[!foo]] into a blog page, and its automagically picked up by the RSS feed and a categoryfoo/category gets added. My problem is that I want the English RSS feed to only link to English articles using English category names, and the French Blog should be similarly set up. Now, I can't just mix them altogether into one Category group, because some labels (like 'blog') are the same in French and English, and I don't want someone looking up Category/Blog to get a mix of languages. I've been thinking of setting up individual Category-like groups (probably 'Tags' for English and 'Balises' for French) and creating links like [[Tags.thing]] and [[Balises.chose]]. This will keep my tags in separate namespaces, but how do I get the separate RSS feeds for the two blogs to each grab the right category pages? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] FOX Question.
Hans wrote: Thursday, October 18, 2007, 9:40:43 AM, Hans wrote: to me it appears the same needs doing for preserving quotes in $InputValues, and not have backslashes added. So the above will be better like: # POST input values will be preserved foreach ($_POST as $k=$v) { $InputValues[$k] = stripmagic(htmlspecialchars($v)); } I hope this is a legitimate approach. Well, in script/forms.php, I find the following: foreach($req as $k = $v) if (!isset($InputValues[$k])) $InputValues[$k] = htmlspecialchars(stripmagic($v), ENT_NOQUOTES); So, it would seem valid, although I notice that PM does the stripmagic first, and that he adds the ENT_NOQUOTES flag. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] FOX Question.
When a filter issues a message and aborts, how do you ensure that the fields that were input aren't blank when the user is returned to the form? I haven't been able to get that to work. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] CondAuth ignores $HandleAuth: Bug?
Patrick R. Michaud wrote: On Sat, Oct 06, 2007 at 05:50:36PM -0400, Stirling Westrup wrote: I've just tracked down a problem that I was having with a statement like: (:if auth upload {$PAGE}:) I presume (and I could be wrong) that this is supposed to test if the user has the authority to upload to page {$PAGE}. The correct way to see if someone can use action=upload on a page would be with (:if action upload {$PAGE} :) Reportedly this isn't working -- I'll have to double check it and issue an update if that's the case. So, this would imply that the Site.PageActions section that looks like: (:if auth upload:) * [[{*$FullName}?action=upload | $[Attach] ]] (:ifend:) Should be changed to say (:if action upload:) instead? Since all that is being checked is whether its appropriate to show an upload link, and it seems silly to show one in cases where it won't be allowed. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] CondAuth ignores $HandleAuth: Bug?
I've just tracked down a problem that I was having with a statement like: (:if auth upload {$PAGE}:) I presume (and I could be wrong) that this is supposed to test if the user has the authority to upload to page {$PAGE}. It turns out that auth calls CondAuth, which (among other things) tests $AuthCascade, but it completely ignores $HandleAuth. In my config.php, I have the lines: $DefaultPasswords['admin'] = '@admins'; $DefaultPasswords['edit'] = '@editors'; # Anyone with edit rights also has upload rights. $HandleAuth['upload'] = 'edit'; So, although the standard (:if auth upload:) is false, I can, in fact, do an ?action=upload, and it will work. I fixed it by redefining auth as follows: # redefine 'auth' so it cares about $HandleAuth $Conditions['auth'] = 'NoCache(CondAuth2($pagename, $condparm))'; function CondAuth2($pagename, $condparm) { global $HandleAuth; @list($level, $pn) = explode(' ', $condparm, 2); $level = array_key_exists($level,$HandleAuth) ? $HandleAuth[$level] : $level; $pn = ($pn '') ? MakePageName($pagename, $pn) : $pagename; msg(lvl=$level, ha=$HandleAuth[$level], pn=$pn); return (boolean)RetrieveAuthPage($pn, $level, false, READPAGE_CURRENT); } And now everything works as I expected. So, did I find and fix a bug, or did I just mess things up in some subtle way that I don't yet understand? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] BUG: Ampersand escapes broken.
I was just checking out an old page on my PmWiki where I wrote about HTML character entities, and I discovered that sometime in the last bunch of upgrades, ampersand escapes have broken. I have sentences where the wiki-text is: Thus, the string 'amp;#x251C;' is rendered as '#x251C;'. This used to end up as-in in HTML, and would be correctly rendered by my browser. Now, however, the output HTML is this: Thus, the string '#x251C;' is rendered as '#x251C;'. Which isn't at all what I want. I was able to duplicate this problem on the PmWiki site: http://www.pmwiki.org/wiki/Test/Ampersand Although, on my site, even the last case, with double-escapes, renders the same as the first two. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Bizarre permission problems.
H. Fox wrote: On 9/21/07, Stirling Westrup [EMAIL PROTECTED] wrote: As part of an ongoing experiment, I just backed up my PmWiki installation, renamed it main directory, and recovered it to the old location. Something went wrong somewhere, and although all the files were restored correctly, some of the permissions got mangled. Did you use one of the restore procedures described here? http://www.pmwiki.org/wiki/PmWiki/BackupAndRestore No, since what I wanted wasn't covered there. I need to: a) mirror the wiki between two sites b) have the wiki be in a subversion repository at one of those sites. This should be readily doable with a rsynch script, but my first test went horribly wrong. As far as I can tell, I've done something to prevent Php's session variables from working correctly, but I'm darned if I can figure out what. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Bizarre permission problems.
As part of an ongoing experiment, I just backed up my PmWiki installation, renamed it main directory, and recovered it to the old location. Something went wrong somewhere, and although all the files were restored correctly, some of the permissions got mangled. Now though, I find that I can't log in or out of the Wiki. Or, sometimes I can, but it has completely inconsistent results. I have sections of my menus that are supposed to appear when I'm logged in with edit, or with admin rights. They're appearance now doesn't change when I attempt to log in, or out, and I've even had cases while I've navigated to Site.Sidebar that the display of the sidebar in the main window and the sidebar itself disagree on whether I'm logged in. What on earth could be causing this, and how do I fix it? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Bug in variables inside Page List Templates?
I think I just found a bug in variable processing inside page list templates. I've defined $SomePage as a PageVar: $FmtPV['$SomePage'] = '$GLOBALS[SomePage]'; For must uses, this variable works fine, but if I create a template #foofmt (:template trail={$SomePage}:) Stuff #foofmtends The trail doesn't get accessed when I do a (:pagelist fmt=#foofmt:), but everything works if I manualy expand {$SomePage} inside the template's 'trail=' parameter. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] PTV Confusion.
What are the legal characters in the name of a PTV? Looking at the regexes inside pmwiki.php (latest version), I see: $PageTextVarPatterns = array( 'var:'= '/^(:*\\s*(\\w[-\\w]*)\\s*:[ \\t]?)(.*)($)/m', '(:var:...:)' = '/(\\(: *(\\w[-\\w]*) *:(?!\\))\\s?)(.*?)(:\\))/s' ); Am I reading that wrong, or doesn't [-\\w] match any word character plus '-'? The reason I ask is that I can get simple PTV's to work, but not those that contain '-' in the names. I wish to have a bunch of entries like: Cat-A:one Cat-B:two and so on. I'm sure I could play with the $PageTextVarPatterns, if need be, but I can't figure out why it doesn't already work. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] XLPage()
As part of this multilingual site I'm creating, I've been playing around with XLPage() and the various other XL...() mechanisms for handling translations. I've noticed a few things that I would like, but that would probably involve changes to the core: 1) Right now, every time you call XLPage(), and it loads anything, it unconditionally adds the language tag to the end of $XLLangs, even if its already there. Thus a sequence of commands like XLPage('fr',$Group.XLPageLocal);# group local translations XLPage('fr','PmWikiFr.XLPageLocal'); # my local translations XLPage('fr','PmWikiFr.XLPage'); # from i18n.tgz Ends up with 'fr' showing up three times in $XLLangs. I think this implies that an untranslated phrase like $[FOO] will be looked up three times in $XL['fr'] before PmWiki decides it doesn't exist. It also means that one cannot stop using a loaded translation just by doing an array_shift($XLLangs); It should be fairly straightforward to only append a language tag if its not already in the language list, shouldn't it? 2) I've sometimes found myself wanting to translate a phrase OUT of the current language, not into it. Thus, in English text I may want to say something like: While the menu will say 'edit' before you've selected a language, it will change to '$[edit]' after you choose French. This is especially important when such strings are being auto-generated. Now, naturally that isn't going to work, without some way to tell PmWiki what language to translate something into. I would love to have a way to specify a target translation mechanism like $[fr|edit] or something that could do that, but I fear that it might have a large impact on how PmWiki handles current translations. What do people think? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Suggestions for Parallel Language versions of Pages.
I'm currently working on a Bilingual (English/French) site where most of the pages in the English/ group will be mirrored by a translation in the Francaise/ group and vice-versa. I would like to have a Francaise button in the English group which takes you to the equivalent French page, and an English button in the French group which takes you to the equivalent page. The question is, how should I best go about setting up these page equivalences? I can imagine a few methods such as: 1) Each page in either group has a (:Alternate: ... ) PTV pointing to the other page. 2) Each page lists other pages by language, so that you might find an (:English: ... ) PTV in French pages and vice-versa. This allows me to expand the language list later (although I'm not sure we ever will). 3) There's some strange two-way XLPage set up that maps pages back and forth. This was my initial plan, but its now looking difficult to set up. 4) Something I haven't thought of. So, what do folks suggest? It would be best if the system made it obvious when the translation of a page (or its link) was missing, and that would be simple to extend to other languages if need be. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] 2009 WorldCon in Montreal.
Some time ago I mentioned here that I was involved with some folks who were trying to get the 2009 World Science Fiction Convention to be held in Montreal. I'm happy to announce that they just won. What does that have to do with PmWiki? Well, the bid site was planned to be moved over to PmWiki (since it was hosted on my system, and its what I was most familiar with), but I've been waiting on the core blogging routines, which have still yet to appear. Now, however, I'm out of time. This week we're replacing the bid site with a WorldCon site, and we've made the decision to run it on top of PmWiki. At first it will only need a bilingual blog but soon it will want a whole host of convention-specific add-ons to help the convention organizers communicate, plan and run the convention. Now this is going to be a very ambitious project for one person, even if I have a year before most of the features need to be in place, especially as its not my day job. So, if there are any folks on the list who would like to volunteer some time and effort to helping make the 2009 WorldCon a success by doing some PmWiki work, I would be eternally grateful. Naturally, all work will eventually show up as public domain (or GPL) add-ons in PmWiki's cookbook section. We may even build a specific bundle of recipes for convention running. There /may/ even be some monetary compensation available down the line, but I can't promise anything. WorldCon's tend to run on a shoestring, and I never got any compensation (other than a discount on my hotel room) for the many hours of work I did on the 2003 WorldCon's internal website. In fact, any money that might become available in compensation is most likely to be a tiny fraction of what the work would actually be worth if done for hire. If you've read this far, and are still interested in possibly helping out, please contact me! ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Map Overlays?
I'm planning to use a PMWiki to hold notes for a tabletop roleplaying game. One of the things that are standard to such games are keyed maps. I would love to have some way to put up a map image on a page, and then overlay icons on top of it, so that one could click on an icon and be taken to an explanatory page. Of course, this would require some elegant way of placing icons on top of an image and making sure they rendered in the correct location, regardless of browser. Does anyone have any suggestions as to how I would best do this? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Update to PmWiki.SkinTemplates
I've finished making a large number of changes to the PmWiki/SkinTemplates page at: http://www.pmwiki.org/wiki/PmWiki/SkinTemplates and was looking for feedback and/or further edits. I'm not all that happy with the final results, but I think its an improvement over what was there before. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Report on Various Skins.
Since I need to create a couple of new PmWiki sites with particular looks, I was browsing through the list of all current PmWiki skins, and a number of the skin pages don't display in their own skins. I gather that PM has to do something to enable them, so I'm making a list here of the ones that seem to need enabling. http://www.pmwiki.org/wiki/Cookbook/BarthelmeSkin http://www.pmwiki.org/wiki/Cookbook/BlueBerrySkin http://www.pmwiki.org/wiki/Cookbook/NewsPaperSkin http://www.pmwiki.org/wiki/Cookbook/PmWiki2Bars http://www.pmwiki.org/wiki/Cookbook/SimplaSkin http://www.pmwiki.org/wiki/Cookbook/SimpleTabSkin http://www.pmwiki.org/wiki/Cookbook/SinorcaSkin http://www.pmwiki.org/wiki/Cookbook/MarathonSkin http://www.pmwiki.org/wiki/Cookbook/NotebookSkin http://www.pmwiki.org/wiki/Cookbook/Notebook2Skin (may not be safe to enable!) http://www.pmwiki.org/wiki/Cookbook/SchlaeferTwoSkin Since I wanted to find out what these looked like, I've downloaded all of the above and tried them out on my farm. They all sort-of work (at least under firefox) with the following exceptions that someone might want to look into: A) For SimpleTabSkin, I had to change $PubDirUrl in the .tmpl file to $FarmPubDirUrl to make it work in my farm. It should actually be using $SkinDirUrl instead, so it would work anywhere. B) For PmWiki2Bars I was surprised that it expects to be unzipped in the main pmwiki directory, while most skins expect to be unzipped in the pub/skins directory. C) MarathonSkin expects to find a Main.TopNav and a Main.SideBar page which don't exist. The Main.SideBar should be changed to Site.SideBar, and a Site.TopNav should be supplied via a local wikilib.d file. D) The Notebook2skin has a message on its page about a javascript injection bug. I haven't determined if its been fixed or not. E) The SchlaeferTwoSkin contains some extraneous Mac OSX files in its zip archive, and its old enough to use Main everywhere instead of Site. Most of the above fixes would be easy enough for me to make (except that I don't know javascript, so I can't debug it), but I don't want to step on any toes. Does anyone know which of the above skins have been abandoned by their creators? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Footnotes and Endnotes?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 noskule wrote: Stirling Westrup schrieb: A quick search for 'footnotes' and 'endnotes' on PmWiki didn't find me anything relevant. Is there such a more-advanced recipe, or will I have to construct my own? As starting point: One could simply design a markup that makes links {*$Group}{*Name}-Footnote-FootnoteName and display them via groupfooter (:pagelist name={*$Group.{*$Name}-Footnote-* the question would be howto name FootnoteName what you think? I'm thinking I want something that is related to the only existing footnote recipe in MarkupExtensions. That will make it easier for someone transitioning to the newer system. So, I was thinking something like this: [^footnote text^] - Remember text. Make a reference (from MarkupExtension). [^#^] - Spit out the next footnote (form MarkupExtension). [^^#other^^] - Make a reference to footnote '#other'. Use group.page#other for a different page. (:footnote #other:) - Start of text for footnote '#other'. (:footnote:) - End of current footnote. (:footnotelist args:) - Produce all footnotes via pagelist-like mechanism, including templates. The idea is to support things like lists inside of footnotes (which don't currently work if the reference point is, for example, inside a table) and to allow for separate pages and areas in which to compose long footnotes, so they don't get lost in the running text. All the above is just off the top of my head though. I haven't thought out any of the details yet. I just wanted to know what similar recipes existed first. Besides, I need to finish this skin I'm working on before I start another recipe. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.3 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFGVLBb5dZZEoPlyIURAu7cAKCdcw8LYKQDZnhbkAgldwmI750HbgCgm54g A1FfUz8rnRN/cYu8uTStZhc= =PNWl -END PGP SIGNATURE- ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Is 'RightBar' the right name?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Tegan Dowling wrote: OR have a LeftBar and RightBar but have NO fixed contents in either one, and instead populate each only via includes, and name the includables for their functions - GroupMenu, LinksMenu, ToolsMenu, etc. That is more-or-less what I plan to do. The thing is, standard markup has a (:nosidebar:) directive, so I need to decide which bar that affects. I can easily make it be either one. In either case, I still have the interesting problem of defaults. I'll probably have the left sidebar default to including Site.Sidebar, as that's quite common, so should the right sidebar include Site.Altbar, or what? Maybe it should just default to not being there? -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.3 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFGUvMp5dZZEoPlyIURAogXAJ0ccSsVTJCYtDNTfE5WYEHj7tPLzQCgpvN6 zOjVUjReGtTVL9BoWY5591E= =6kMw -END PGP SIGNATURE- ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Problem with $FmtPV;
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Ben Wilson wrote: I am setting $FmtPV with the following value: '2007W19'; This is how I set it, outside of any function, but in a recipe. $FmtPV['$YearWeek'] = '2007W19'; This won't work. The contents of $FmtPV are run through eval. That means it has to be a valid PHP expression. 2007W19 isn't one. You need to do something like this: $FmtPV['$YearWeek'] = '2007W19'; Because 2007W19 *is* a valid expression. If you need to use the value of a (non-global) variable, you'd do it like this: $FmtPV['$YearWeek'] = ''.$MyVariable.''; If $MyVariable contains a string with quotes though, things get a bit messier. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.3 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFGUwT05dZZEoPlyIURAl0pAJ97sphEtX6YXzyg4JWKGrstgGOy4gCeMAZW 0/MidNKzn/20AA4xzSzTo1M= =geB3 -END PGP SIGNATURE- ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Footnotes and Endnotes?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Currently I'm using MarkupExtensions when I want to add footnotes to an article. For simple things its adequate, but today I found myself wanting a much more powerful footnoting recipe (where, for example, the text of the footnote could be stored on a different page). I could swear I remembered folks talking on this forum about creating such a thing, but I don't remember any details. A quick search for 'footnotes' and 'endnotes' on PmWiki didn't find me anything relevant. Is there such a more-advanced recipe, or will I have to construct my own? - -- Stirling Westrup -- Visionary, Technology Analyst, Researcher, Software Engineer, IT Generalist LinkedIn Profile: https://www.linkedin.com/e/fpf/77228 Website: http://www.pooq.com Tech Blog: http://technaut.livejournal.com Business Blog: http://willcodeforfood.livejournal.com - -- Spread the word: Its all a HOAX, memes don't exist! -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.3 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFGU8un5dZZEoPlyIURAuC8AJ9nrii/0TAza90gox+vAVzqB5B79ACbBvon Fezyg1hVEdrGroTBdTj7xOA= =WoJn -END PGP SIGNATURE- ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Slashdotting?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Neil Herber (nospam) wrote: On 2007-05-12 Stirling Westrup is rumoured to have said: So, what's the best way to prepare PmWiki for a possible slashdotting? Any advice would be appreciated. A page of mine (Alas! not PmWiki) was slashdotted twice on a machine that was much more heavily loaded and much less powerful than yours. The uplink speed was 1.2 Mbit/s. I had no idea it would be slashdotted, so I was not prepared at all. The only effect was that the mail server running on the same box slowed down a bit. I did get some very impressive (to me) activity graphs from the web server (WebStar on Mac OS9). The slashdotting peaks lasted about 8 hours. Thanks for the info. That helps a lot to know. -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.3 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFGR7an5dZZEoPlyIURAs1eAJ9k/3FDbmSJnxIbcKxa7YXWktq3zACeJrDV RhgxsSZfdkpD9k40GYP4NeQ= =T6ue -END PGP SIGNATURE- ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Slashdotting?
I've recently come up with an idea for something to put up on one of my PmWiki's that might end up being quite popular -- possibly even ending up on slashdot or digg. I don't know how likely a scenario that is -- but its certainly possible. In some ways, this is both a best- and a worst-case scenario. Its best in that it gives me the most leverage in accomplishing my goals (eyeballs == power!) but if it kills my system, then its all wasted. Now, the wiki is currently running on a 2.8 GHz machine that doesn't do anything but serve web pages and handle mail. The total traffic for all other websites on the machine combined is negligible. Its only sitting on a 3 Mbps line, so there a real limit to what bandwidth it can see anyway, so maybe I'm worrying for nothing. (I really can't afford to try this experiment on heftier equipment). So, what's the best way to prepare PmWiki for a possible slashdotting? Any advice would be appreciated. At the same time, if anyone has a pointer to a recipe for including Google AdWords on a page, I would like to see it. That way I might have a chance of partially offsetting my bandwidth costs if this idea does take off. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Best Blogging Recipe?
Stirling Westrup wrote: I've been delaying adding Blogging support to a particular project until PM finishes his Blog support in core, but I can't really wait any longer, and the core support still hasn't shown up. I'd still like to use the core blogging support when it arrives. In the meantime I guess I'll use one of the existing blogging recipes, and then transition to the new core methods when they show up. So, my big question is: which of the many blogging recipes will give me something that is the easiest to convert to the core blog system, once it exists. Does anyone have any ideas? I should perhaps clarify that by the above I mean the best blogging recipe WITHIN PmWiki. I'm not really looking for endorsements of blogspot or wordpress. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
[pmwiki-users] Best Blogging Software?
I've been delaying adding Blogging support to a particular project until PM finishes his Blog support in core, but I can't really wait any longer, and the core support still hasn't shown up. I'd still like to use the core blogging support when it arrives. In the meantime I guess I'll use one of the existing blogging recipes, and then transition to the new core methods when they show up. So, my big question is: which of the many blogging recipes will give me something that is the easiest to convert to the core blog system, once it exists. Does anyone have any ideas? ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Inserting files from the local file system
Petko Yotov wrote: On Sunday 08 April 2007 04:47, Steven Benmosh wrote: Two questions/problems I am running into: 1. I have pmwiki set up in my web server root. I have a directory called images, with image files in it, including one called SantaBarbara.jpg. I would like to attach the image to a wiki page. I can do it by linking to the actual url of the file, in the form http://my.web.site/images/SantaBarbara.jpg. I am wondering if there is a simpler way to connect to a local file, maybe with a relative link, without having to type the whole url and create a static link (that would not change if I move the wiki to another site)? Yes, you can use a Path: link to point to files on the server, but that are not on the wiki uploads directory structure: Path:/images/SantaBarbara.jpg If the link ends with .jpg, .gif or .png, it will be considered as an inline image. To add a tooltip title, use Path:/images/SantaBarbara.jpgView from Santa Barbara To only link to the file, use [[Path:/images/SantaBarbara.jpg|this is a link]] This way you can also link to other files on the same website, like old HTML pages. See also: http://pmwiki.org/wiki/PmWiki/InterMap Like Petko said, Intermaps are the way to go. You can also define a custom intermap entry so that you would just use Image:SantaBarbara.jpg If you ever move the wiki, all you would have to redefine is the intermap definition for Image. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Drafts, moderated wikis, and PITS 00755
Hans wrote: Saturday, March 31, 2007, 9:27:37 PM, Patrick wrote: When drafts are enabled, the edit form has the following buttons [Publish] [Save draft] [Save draft and edit] [Preview] [Cancel] The Publish button always saves to the page without a -Draft suffix. The Save draft and Save draft and edit buttons always save to a page with the -Draft suffix. I never used 'Drafts' before. It took a bit getting used to the different behaviour: when opening the page I am actually opening a -Draft page and not the page! I am pleased how it works though. And I was amazed that the buttons were all there using Triads custom edit form. Only the grey-out of the publish button does not come across. How did you accomplish the styling for that, Pm? Then I got once more confused when setting and resetting the publish password, as for the latter I was trying to do it for the -draft page without realising it. I had the exact same experience, in that I accidentally set the publish password on the -Draft page as well. Still, it was fairly easy to figure out what I had done wrong and fix it. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users
Re: [pmwiki-users] Drafts, moderated wikis, and PITS 00755
Patrick R. Michaud wrote: Given that we've had a couple of recent requests for moderated posting on a wiki, I'd like to go ahead and resolve PmWiki's edit draft feature. Pico put together an excellent page at http://www.pmwiki.org/wiki/PITS/00755 that describes the current state of edit drafts. His comments are recommended reading, but I'll also try to summarize things here. The basic issue is that we want clearer labels on the save buttons in the edit form when drafts are enabled. Currently, when $EnableDrafts is set, a new Save as Draft button appears on the edit form. Thus the typical buttons are [Save] [Save and edit] [Save as draft] [Preview] [Cancel] The [Save] button saves the page, as normal. The [Save and edit] button saves a copy of the page, but also returns the browser immediately to the edit form so the author can continue editing. The [Save as Draft] button saves the current page and any changes to a new page with a -Draft extension added to the pagename. When an author attempts to edit a page for which a -Draft version exists, the author always gets the -Draft version to edit. Thus we don't have a case of draft edits being lost. The confusion arises when the buttons above are presented on the -Draft page, because it's not completely clear what Save (and possibly Save as draft) will do. Thus it appears we need alternate labels for these buttons editing a draft. I just need to know what labels we want to use that will make sense to people editing drafts. Currently the [Save] button always saves back to the original page without the -Draft suffix, and removes the -Draft version of the page. The [Save as draft] button saves back to the -Draft page. This can be a bit confusing, because some people expect [Save] to save back to the -Draft, and they don't see a button that clearly indicates they're saving to the original. So far the best idea I've seen is to use [Publish] to mean save to original, but I want to see if there are any other suggestions before committing to it in the core. In each case (original page and draft), the actions are essentially the same: - save page to original location - save page as -Draft version - save and keep editing - preview - cancel editing All that differs is the labels. The current approach I'm considering uses the following labels for editing the original page: - save page to original location [Save] - save page as -Draft [Save as draft] - save and keep editing[Save and edit] - preview [Preview] - cancel editing [Cancel] And when editing a -Draft page: - save page to original location [Publish] - save page as -Draft [Save as draft] - save and keep editing[Save and edit] - preview [Preview] - cancel editing [Cancel] As far as moderating posts go, there will likely be some sort of option that hides/disables the Save and Publish button for moderated authors. Such authors would then be able to edit pages (as drafts), but only a moderator/admin would be able to publish the draft back to the original location. Comments and questions greatly appreciated. I took the time to set up alternative buttons for myself a while ago. After much experimenting, I found that what worked best for me (single author who only cares about visibility. ie. Publisher and Draft writer are both me.) was the following: When editing a -Draft page: - save page as -Draft [Save Draft] - save and keep editing[Save Draft and Edit] - preview [Preview] - cancel editing [Cancel] [Next button is flush right] - save page to original location [Publish] When editing the original page: - save page to original location [Save] - save and keep editing[Save and Edit] - preview [Preview] - cancel editing [Cancel] [Next button is flush right] - save page as -Draft [Save as Draft] I found the above arrangement with the flush-right buttons very convenient as I had grown used to the standard button layout, and sticking the [Publish] and [Save as Draft] anywhere other than off to the right caused me to hit the wrong buttons out of habit. Also, I often don't work with a -Draft version, if I'm writing something short. Of course, this order would not be as good for a site where there was a strict review process and all some folks ever saw was 'Save as Draft'. ___ pmwiki-users mailing list pmwiki-users@pmichaud.com http://www.pmichaud.com/mailman/listinfo/pmwiki-users