Custom Button OnClick

Robert McDonnell created the topic: Custom Button OnClick


I'm a bit confused with the OnClick feature in the Custom Button field. What I want to be able to do is use it as a link to direct to a product page.
I am not sure as to how to do this. I did the obvious (and probably dumb) thing and simply copied and pasted the link into the OnClick section.
I know that there is a URL link that does that but call me picky, I prefer the button over the simple writing.

Thank you,


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

Anoush replied the topic: Custom Button OnClick

Dear Robert,

Thanks for your post :)

You can show us what have you added for custom javascript.

Take a look the below code, your code should look something like this:

<button id="myButton" text</button>

<script type="text/javascript">
document.getElementById("myButton").onclick = function () {
location.href = " ";

Thanks and have a nice day!


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

Time to create page: 0.153 seconds
Powered by Kunena Forum


We are here for you every step of the way. Turn to our support with any questions you might have about our products and services. Our experienced customer care team is available to help you as fast as we possibly can.

Contact us