[pmwiki-users] Workaround for fox form redirection problem

Hans design5 at softflow.co.uk
Sun Apr 13 13:07:03 CDT 2008

Sunday, April 13, 2008, 5:23:34 PM, Randy Brown wrote:

> c) You mention referring to anchored sections as PTVs. Does that mean
> I should not (or cannot) continue to use section editing for non-PTV  
> text? Perhaps the section edit functionality is not intended for  
> arbitrary text? Surely I misunderstand you.

foxedit.php contains markup definitions which make anchored sections
of form
into PTVs, meaning such section can be treated as a PTV of name
'sectionname' (without the #).
BUT at the same time it can be treated as a page section by using
There are different edit form models for both cases, even though the
resulting saved page is just the same.
So you can use section editing for anchored sections, and thse
sections can contain anything, even PTVs (as PTVs are really just
content in special formats).

> In summary, it would be a shame if I can no longer use Foxedit with my
> design, but I'll understand if my design is not what Foxedit is meant
> to do. If it's not, any suggestions on other recipes to accomplish  
> what I want would be appreciated.

If I would but understand your intentions fully I may be able to
offer some good solution.

I am aware that at present there is
a restriction in that error messages are lost when a redirection
happens. So i can try to fix that to make Fox able to display
messages even after redirections.

There is another restriction regards foxedit which returns one to
the calling page when aborts happen due to invalid input or other
errors. I thought this as an improvement, as one is not stuck on the
form page suddenly, but returned from where one started.

But if the abort happens as a result of an invalid input initiated
by a foxedit action, then one is taken away from the edit form, and
any form input is lost. So perhaps a special redirection option needs
to be added. Or a different mode to open the edit form, which will
not lead to the calling page on aborts. I have to think abouth this a
bit. This may address your point a)

Your point b) I don't really understand.

> 1) THE-ADD-A-LINE-LINK: leaves the calling page and goes to the edit  
> form page. (If I knew how to make a modal pop up edit window, I would
> do it that way instead.)

You probably could use togglelink.php
see http://www.pmwiki.org/wiki/Cookbook/ShowHide

for instance with

(:toggle div=popform init=hide lshow='add line' lhide='hide form':)
(:include PopForm:)

PopForm is your fox form to add aa line. Or put the form directly into
the div   >>id=popform<<

> 2) THE-EDIT-SECTION-LINK: uses foxedit's section editing to provide a
> separate-page window into a section, so that the user is only editing
> the section. The section's lines might contain anything arbitrary,  
> including PTVs.

{[foxedit #sectionname]}


More information about the pmwiki-users mailing list