[pmwiki-users] Suggestion: $PostTargetUrl-Variable
nk at knappi.org
Thu Sep 21 11:50:18 CDT 2006
> For now, I think that if we have a $PostTargetUrl, it should be
> established by convention as opposed to being designated in the core.
> I.e., recipes can easily do:
> SDV($PostTargetUrl, $ScriptUrl);
> But I really don't think we need or should have a separate variable for
> this -- see below...
Well, I think I have now done it without the $PostTargetUrl. It really
It also works, when I use the $PageUrl with FmtPageName instead of
$ScriptUrl, so that the path information is appended.
>> The reason is simple: A lot of recipes (at least my AddDeleteLine and
>> MailForm) use POST-requests, then process the data and perform a
>> redirect back to the BrowseHandler of the page. When you use CleanUrls,
>> it does not work, e.g. on pmwiki.org, to do a
>> <form target='http://pmwiki.org/wiki' method='post'>...</form>
>> because the rewrite engine will redirect the request to something like
>> http://pmwiki.org/wiki/pmwiki.php, which results in the loss of all
> Actually, this isn't precisely true in many respects. First,
> using mod_rewrite with CleanUrls (as described in the Cookbook)
> does *not* cause a redirect or lose POST variables. If it did, then
> nobody would be able to post edits or enter passwords when using
> CleanUrls, and clearly that's not the case.
> There may be some sites that have mod_rewrite configured to do
> things using browser redirects instead of local rewrites, but I think
> those ought to be the exception and not the rule, and then I'm
> very curious to know how they're getting other things in PmWiki to
> I also want to note in passing that
> <form action='http://www.pmwiki.org/wiki' method='post'>...</form>
> works just fine with pmwiki.org. (pmwiki.org isn't using mod_rewrite.
> Even if it were, the above would work.)
>> Since such a variable might be of use for a number of recipes, I would
>> suggest adding it to the core of PmWiki.
> It seems to me that a recipe that wants to do POST should be able
> to do exactly what PmWiki does when it performs POST operations.
> If that's not the case, then I'm curious to know why things are
> different for the recipe.
> Lastly, we already have at least five PITS items open that are trying
> to "fix" perceived problems with $ScriptUrl:
> I'd much prefer to come up with a solution that addresses all of
> the problems, rather than come up with separate variables that
> has to be set and maintained for each.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 3318 bytes
Desc: S/MIME Cryptographic Signature
Url : /pipermail/pmwiki-users/attachments/20060921/83efb35b/attachment.bin
More information about the pmwiki-users