How I can have a reset button in a search forms? (like version 9).
Thanks for any insight!
Marco.
How I can have a reset button in a search forms? (like version 9).
Thanks for any insight!
Marco.
Hi Marco,
The search form Reset button is already available in WebLink 10.1.
If you want to have a reset button in WebLink 10, you would have to do the following:
1- Under C:\Program Files\Laserfiche\WebLink\WebLink\Web Files\Custom\searchforms\YOUR_REPO_NAME, look for YOUR_SEARCH_FORM_NAME.xml (not the YOUR_SEARCH_FORM_NAME.designer.xml) and open to edit.
2- Look for a line:
<lf:Submit runat="server" id="YourSearchFormName_ButtonNumber" Text="Submit" />
and directly under that line add in a new line of code:
<lf:Reset runat="server" Value="Reset"/>
so it will look similar to this:
<UI> <table> <tr> <td> .... </td> </tr> </table> <lf:Submit runat="server" id="YourSearchFormName_ButtonNumber" Text="Submit" /> <lf:Reset runat="server" Value="Reset"/> </UI>
3- Save the xml, and refresh the browser.
However note the following:
1- The reset button will not be added to Search form preview. It is only available when accessed from welcome page custom links
2- The same steps need to be repeated whenever the search form is updated from the designer (that means any updates: delete/add new fields, change of field names etc)
3- If you would like to see it in every search form, you would have to do the same for every YOUR_SEARCH_FORM.xml inside the <searchforms> folder.
Hope this helps!
Thanks,
Julia