|
|
|
|
<?
$page = 0;
$URL = "http://www.beginnersphp.co.uk/";
$page = @fopen($URL, "r");
print("Links at $URL<BR>\n");
print("<UL>\n");
while(!feof($page)) {
$line = fgets($page, 255);
while(eregi("HREF=\"[^\"]*\"", $line, $match)) {
print("<LI>");
print($match[0]);
print("<BR>\n");
$replace = ereg_replace("\?", "\?", $match[0]);
$line = ereg_replace($replace, "", $line);
}
}
print("</UL>\n");
fclose($page);
?> | | |
|
| Gets the browser and OS from the $_SERVER['http_user_agent'] variable in PHP Categories : PHP, HTTP, Regexps | | | PHP Domain Availability Checker Categories : PHP, Complete Programs, Regexps, HTTP, Sockets | | | How to strip non-alpha characters from a string Categories : Regexps, PHP | | | IP Blocking Categories : PHP, Security, HTTP | | | Get the AppStore Ranking for any iPhone App Categories : PHP, Web Services, Regexps | | | Produces browser-safe strings while preserving HTML tags. Categories : Strings, HTTP, PHP, HTML and PHP | | | Identify and log search engine access (spiders, robots, etc.) to a page. Categories : HTTP, Environment Variables, PHP, MySQL, Databases | | | A simple script to count and report hits and the last
modification time of an HTML page. Requires MySQL support
(other DBs should work too, except possibly mSQL). Categories : HTTP, MySQL, PHP, Databases | | | Newbie Notes #7 - Ridiculous regex Categories : PHP, Beginner Guides, Regexps | | | grab the result of any calculation you submit to the Google Calculator. Categories : PHP, Arrays, Web Services, Regexps, Math. | | | Check if a file exists on a remote FTP server with PHP Categories : PHP, FTP, Regexps | | | Class that allows the PHP developer to create and manage UNIX like password files suitable for use as Apache authentication password files.
Categories : HTTP, PHP, PHP Classes, Filesystem | | | The GTV.class allows you to extract a value between any HTML tag or between any TEXT on a web page. Categories : PHP, PHP Classes, Regexps | | | validateEmail 2.0 - upgraded version of the old validateEmail function used to validate email
addresses via SMTP and regex. Categories : Email, Regexps, PHP | | | BBCode Formatting String Categories : PHP, HTML, Regexps, Arrays | |
| | | | Tim N wrote :1689
Please take a look at the function posted by
"max99x [at] gmail [dot] com" at http://de.php.net/preg_match/.
Your function does not get the links Javascript import links, CSS links, and the regular URL/SRC HTML links.
| |
|
|