Hello guyz, I'm glad I finally back here.

I need help using the preg_match function.
I am scraping url and I need to get the specific value from the html tags.
Here is the string <p><b>1,664</b> Referring IP addresses</p>, I need to get 1,664 How can I achieve it using php?

preg_match('@<p><b>(.*?)</b>@i', '<p><b>1,664</b> Referring IP addresses</p>', $matches);
print_r($matches);

Thank you pritaeas, it works.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.