I´m traying to create a dynamic button with jquery and API Redsys. But i want to change value for default to this button and i´m traying to do this:
$("#btn_submit").val('Pasarela de pago TPV - ' "<img src='{{ asset('media/santander.png') }}' name='logo' /> ");
and result it´s:
i want show this img in my button.
Anybody can help me?
Thanks
CodePudding user response:
You could like this:
e = "<img src='{{ asset('media/santander.png') }}' name='logo' />";
$("#btn_submit").html(`Pasarela de pago TPV - ${e}`);