kunal kunal - 2 months ago 53
Javascript Question

onclick not working on button laravel 5.2

I am working on Larvel framework. I am using login blade file of auth component. There is one button of register. whren i apply onclick on button to register page it is not redirect to register page.

<button class="btn btn-info sign-bttn" onclick="{{ url('/register') }}">Register Your Business</button>


Where i am doing wrong anyone help me

Answer

You can use the anchor tag instead of button and use the same class as you define in button

<a class="btn btn-info sign-bttn" href="{{ url('/register') }}">Register Your Business</a>
Comments