Is it possible to import the number of visitors into a Foundation Billboard stack?

Hi! Our company is running a campaign and they would like me to display the number of page hits inside @tav’s Billboard stack (see http://jellysign.com…instead of “123,” they would like that number to update every time someone else views the page).

Is this posible? I tried using hit counter scripts, but it seems to just mess up the page. It seems like it should be something that is fairly simple to do…make the number of page hits appear inside a stack. However, I can’t seem to make it work.

Any ideas?

1 Like

Yes it is, I’ve made you a simple demo - you can download all the files required from the link on the page

https://demo.bigwhiteduck.com/bb-hitcount/

4 Likes

Wow! This is amazing Andrew! Thank you so much! I had tried something similar with another PHP hit counter script that I found on the internet, but I didn’t use a PHP include and it didn’t work properly.

Thank you!!

I suspect that if you were using a script tag inside BillBoard then that was messing things up. Doing it this way means that the counter text is inserted server side so BillBoard just sees the text as if you had entered it yourself when the page JS runs.

1 Like

Yes, your way is much better! I don’t know enough about scripts to figure
all of that out on my own…

Really appreciate the help, Andrew! Enjoy the coffee :wink:

3 Likes

Thanks, much appreciated