Skip to content

Tag: html

PHP Split html string into array

I hope I can get some help from you guys. This is what I’m struggling with, I have a string of HTML that will look like this: I need to split all the <h4> from the rest of the content, but for example the content after the first <h4> and before the second <h4> needs to be related to th…

(PHP) Adding a ‘guess counter’ to a random number game

I need to modify a block of code and add a counter regarding how many times it took the user to guess the right number. I was wondering how it would be properly implemented into my code. This is what I have so far. Answer You have to use PHP Sessions to keep track of the count. All you have