I developed a custom post type.
On my archive page for each post there is a <button>
.
The problem is that I can't put the link to the post in question.
My button is in my loop.
<button type="button" onclick="window.location.href='<?php get_post_permalink();?>'"> Click here </button>
a
element. There's nothing about your code that requires a button.