I’m using Simple HTML DOM Parser and it works pretty fine. In the page which I’m trying to parse I have the following in a JavaScript function:
listCounter.addItem(13981, 'timer_31486');
And I actually need to take “13981” from that string. What I want to do is – find “timer_31486” in the HTML content I get from the parser and take a certain amount of symbols before that string. However I’m not sure how that can be achieved.
Could anybody help me with this?
Thanks in advance.
You should probably use substr() if the length is always the same.
If not, just use str_replace and scrap what you don’t need.