0

I currently have this button on my website, the button changes the theme. I would like to add this function as a text label somewhere else.

This is the code of the button

<li class="ipsMenu_item">
                <form action="//nkips.local/theme/?csrfKey=6d76e45144a958ae2137f7cc1df9ce9b" method="post">
                <input type="hidden" name="ref" value="aHR0cDovL25raXBzLmxvY2FsLw==">
                <button type="submit" name="id" value="4" class="ipsButton ipsButton_link ipsButton_link_secondary">Default Dark </button>
                </form>
            </li>

But I'm not sure how to change this into a text link.

I've changed the "button" to "a".

Tried it with giving the form an ID and use the onclick function but that also doesn't seem to work.

SamDT
  • 21
  • 3
  • Links make GET requests. Your form is making a POST request. If you don't like the way a button looks, apply CSS to it. – Quentin Feb 26 '21 at 19:22
  • Thanks for the tip, following seems decent: button { background: none!important; border: none; padding: 0!important; cursor: pointer; } – SamDT Feb 26 '21 at 20:11

0 Answers0