Questions about Payment Form extension

Need a "Clear ALL" button

  • Daryl Rose
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
9 years 3 months ago #55584 by Daryl Rose
Need a "Clear ALL" button was created by Daryl Rose
As I work on my form, I realize that we need a "Clear All" button. Perhaps the person no longer wants to register, or wants to start over? Right now there is no way to clear out all of the entries. Can this be added?

Thanks

Daryl

Please Log in or Create an account to join the conversation.

More
9 years 3 months ago #55591 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Need a "Clear ALL" button
Hi Daryl

We don't have this button on the form. However, I think you can edit the form layout you are using (for example E:\www\cmsdev\components\com_pmform\view\form\tmpl\default.php), add a reset button to the form, something like this:
Code:
<input type="Reset" value="Reset" />

That should allow users to click on to reset the input of all form fields which the person just entered so that he can start over.

Tuan

Please Log in or Create an account to join the conversation.

  • Daryl Rose
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
9 years 3 months ago #55604 by Daryl Rose
Replied by Daryl Rose on topic Need a "Clear ALL" button
This should work. I'll give it a try, and let you know if it works for me.

Thank you.

Daryl

Please Log in or Create an account to join the conversation.

  • Daryl Rose
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
9 years 3 months ago #55617 by Daryl Rose
Replied by Daryl Rose on topic Need a "Clear ALL" button
Tuan,

I looked at the form in question, but I don't know where to add the reset button. Any suggestions on where I would add this bit of code?

Thanks

Daryl

Please Log in or Create an account to join the conversation.

More
9 years 3 months ago #55619 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Need a "Clear ALL" button
Hi

You can try to get this file, unzip it, upload the file to components/com_pmform/views/form/tmpl folder. After that, it should work as expected

Tuan
Attachments:

Please Log in or Create an account to join the conversation.

  • Daryl Rose
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
9 years 3 months ago #55621 by Daryl Rose
Replied by Daryl Rose on topic Need a "Clear ALL" button
Tuan,

That's a slightly different path than what you told me before. Should it be "view" or "views"?

Thanks

Daryl

Please Log in or Create an account to join the conversation.

More
9 years 3 months ago #55622 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Need a "Clear ALL" button
Sorry, "view", not "views". From version 3.5, I changed the all folder to singular to use Joomla PHP auto-loader feature. The views folder is there now just for backward compatible with Joomla 2.5. It will be removed when we drop support for Joomla 2.5

Tuan

Please Log in or Create an account to join the conversation.

  • Daryl Rose
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
9 years 3 months ago - 9 years 3 months ago #55623 by Daryl Rose
Replied by Daryl Rose on topic Need a "Clear ALL" button
I found default.php in two different locations:

components/com_pmform/view/forms/tmpl/default.php
components/com_pmform/view/form/tmpl/default.php

Which one should I put this fix in?

Thanks

Daryl
Last edit: 9 years 3 months ago by Daryl Rose.

Please Log in or Create an account to join the conversation.

More
9 years 3 months ago #55624 by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Need a "Clear ALL" button
components/com_pmform/view/form/tmpl/default.php
The following user(s) said Thank You: Daryl Rose

Please Log in or Create an account to join the conversation.

  • Daryl Rose
  • Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
9 years 3 months ago #55629 by Daryl Rose
Replied by Daryl Rose on topic Need a "Clear ALL" button
Tuan,

I put the new default.php file in place, but the "reset" button does not appear on the form.

Thank you.

Daryl

Please Log in or Create an account to join the conversation.

Moderators: Tuan Pham Ngoc