?
Solved

PHP Script to check if external page contains a certain html tag

Posted on 2011-04-29
2
Medium Priority
?
369 Views
Last Modified: 2012-05-11
How would I go about getting a PHP script to check an external site's page x for html tag x and return that data on the same server where the script is activated?  So I mean
user enters target url
script checsk that url's home page in  background for tag x
Returns that tag plus content between opening and closing tag to page b (result page) on the same server.
Are there scripts for that out there? Any advice on how to build one?
0
Comment
Question by:rhandalthor
2 Comments
 
LVL 36

Accepted Solution

by:
Loganathan Natarajan earned 1200 total points
ID: 35489987
You can check with cURL, ref. example
0
 
LVL 2

Expert Comment

by:Gk
ID: 35490030
     $weather_feed = file_get_contents("http://weather.yahooapis.com/forecastrss?p=14607&u=f");
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Originally, this post was published on Monitis Blog, you can check it here . Websites are getting bigger and more complicated by the day. Video, images and custom fonts are all great for showcasing your product or service. But the price to pay in…
CTAs encourage people to do something specific to show interest in your company, product or service. Keep reading to learn why CTAs should always be thought of as extremely important, albeit small, sections of websites.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …
Suggested Courses
Course of the Month16 days, 17 hours left to enroll

864 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question