Holiday Notice: Support will be provided on a limited scale from December 24th, 2024, to January 2nd, 2025. Happy holidays and a wonderful New Year!


Topic: Button Color Change After "SUBMIT"

ScorpDevil free asked 5 years ago


Hi,

I'm using a form to add data to a table. I have few inputs and a single submit button. Everything work great and looks great. The problem is after I click the button to submit my form; I'm getting this

div class="waves-ripple"

. Looks like it is to create the effect of button has been clicked. But my problem is that I'm no refreshing/reloading the page. Then the element keeps adding up till you loose the actual color of the button.

Is there a way to disable this function? I just want to button to remain as the original state.

Thanks,SD


Bartłomiej Malanowski staff commented 5 years ago

How can we reproduce this issue?


ScorpDevil free commented 5 years ago

Perhaps creating a form with a submit button, but the form is not refreshing the page or navigating to a different page. The action is ajax and using the response to add data to a table below the form.


Mateusz Łubianka staff answered 5 years ago


Hi,

Try to use this solution: https://mdbootstrap.com/support/general/how-to-remove-waves-effect-on-buttons-with-btn-class/ There is a way how to disable buttons wave effect

Best,


ScorpDevil free commented 5 years ago

I see, but this solution will disable all effect in general. Perhaps there could be a fix when I could use a class name that will disable that particular button and not all at once. something like "no-waves-effect".


Mateusz Łubianka staff answered 5 years ago


Hi ScorpDevil!

Could you create an example of code? I tried to do something with form, submit buttons and getting a data from form. I created a snippet, check it out: https://mdbootstrap.com/snippets/jquery/mateusz-lubianka/1454535

Best regards,


ScorpDevil free commented 5 years ago

I have recreated my form but that will not help with my problem:https://mdbootstrap.com/snippets/jquery/scorpdevil/1460860

you need to fully submit the record and await response from your server and update something in the current page. Don't navigate somewhere else or reload the page. MDB page itself always reloads the page or navigates somewhere after clicking of a button.



Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Answered

Specification of the issue

  • ForumUser: Free
  • Premium support: No
  • Technology: MDB jQuery
  • MDB Version: 4.9.0
  • Device: PC
  • Browser: Google Chrome
  • OS: Windows 10
  • Provided sample code: No
  • Provided link: No