Build a button that displays the number of times it has been clicked in WORDPRESS
<p>Here is my problem: I want to build/program a button that displays the number of times it has been clicked by some visitor on my website.</p>

<p>Basically it is a simple counter. My problem is that I use Wordpress and I don't know how to build it and then integrate it inside Wordpress.</p>

<p>I have tried literally 15 plugins none of them suits this basic requirement. The few that does, don't allow me to set the initial number and I need to be able to do that.</p>

<p>I tried embedding some code in a text block/html block directly inside the page, but it didn't gave me anything. Wordpress doesn't interpret the code correctly or not at all.</p>

<p>So even if I manage to build/program a simple counter in php (which is a langage I do not know but building something as simple as a counter should not be difficult) I do not know how to put it and make it usable in Wordpress. So that is my biggest issue.</p>

<p>If you could help me, it would be great!</p>

<p>Many thanks!</p>

<p>EDIT: It was kindly requested that I add some informations about the button functionality so here it is:</p>

<p>The button would be displayed in a banner at the top of each page.
Any visitor should be able to click on it.
At every click it will increment by one and display the new count.
The page should not refresh, only the counter should be updated instantly.
The value of the counter has to be stored. So that whenever a visitor comes, he will see the current count and could himself click on it to increment it.
The visitor should be able to click on it only once.</p>

<p>I have tried this:
<a href="https://www.dougv.com/2008/12/a-simple-page-click-count-system-using-php-and-mysql/" rel="nofollow noreferrer">https://www.dougv.com/2008/12/a-simple-page-click-count-system-using-php-and-mysql/</a></p>

<p>Unfortunately, when I put the code in a custom html block on wordpress it doesn't work. And I don't know in which folder to put it and how to call it in Wordpress.</p>