By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,521 Members | 1,222 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,521 IT Pros & Developers. It's quick & easy.

Search through website source code using fopen

P: 1

I want to search for the following string through the source code of website '' with fopen;**random id** but do not want to include let's say**random id**.


Expand|Select|Wrap|Line Numbers
  1. $openurl = fopen('', "r");
  2. while(! feof($openurl))
  3.   {
  4. //Which code do I need to use here?
  5.   }
The source code of the website has simple HTML coding and contains several links in one line. These links defer from this:
<img src="">

to this:
<img src="">

What code should I use to find these strings in the above mentioned example coding?
Apr 3 '10 #1
Share this Question
Share on Google+
1 Reply

Expert 5K+
P: 6,050
The PCRE extension to PHP would be useful here. Check out the tutorials and learn some regular expressions.

Apr 4 '10 #2

Post your reply

Sign in to post your reply or Sign up for a free account.