[pmwiki-users] FoxContacts does not seem to empty fields

Hans Bracker design at softflow.co.uk
Mon Aug 25 10:13:09 CDT 2014


> I'm trying to build something based (also) on Fox and particularly FoxContacts.
> I noticed though an odd behaviour when trying to update fields values:
> they are changed with no effort but there seems to be no way to bring
> them back to an empty condition.

change the Fox form on page Contacts/NewContact (or in whatever
group  you  got  the  NewContact  form. This form is used to add a new
contact, as well as editing an existing contact page.

Add to the (fox contactform .... :) markup this parameter ptvclear=1
so it will look something like this:

(:fox  contactform  put=top  target="{$$name1}  {$$name2}" ptvupdate=1
ptvclear=1 template=ContactTemplates#new redirect=1 :)
[all on one line]

ptvclear=1 instructs Fox to allow input of empty fields to clear PTVs.

The  ptvclear=  parameter can also be set with  a list of field names,
each  separated  by  a comma. Then Fox will allow empty input to clear
just those fields, instead of allowing all to be cleared with clear=1.

I  changed the NewContact template page in the download package.
Thanks for the bug report!

Best,
 Hans                         
mailto:design at softflow.co.uk
www.softflow.co.uk




More information about the pmwiki-users mailing list