473,503 Members | 2,105 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Can somone tell me how to mek this script?

Hello, I am very new to php, I need a script, is probably simple for
the ones that know a bit of php:

I need the script to read links from a web page and return them as
variable names, for example to tell it to read file
http://www.adriantnt.com and the script returns (by "echo" i suppose)
variables like:

l1=http://www.adriantnt.com/news.html
l2=http://www.adriantnt.com/contact.html
l3=http://www.adriantnt.com/products.html

Can somone please tell me how this has to be made ?

Thank you.
-Adrian.

Jul 17 '05 #1
1 1170
On 2005-01-20, adrianTNT <ad*******@adriantnt.com> wrote:
Hello, I am very new to php, I need a script, is probably simple for
the ones that know a bit of php:

I need the script to read links from a web page and return them as
variable names, for example to tell it to read file
http://www.adriantnt.com and the script returns (by "echo" i suppose)
variables like:

l1=http://www.adriantnt.com/news.html
l2=http://www.adriantnt.com/contact.html
l3=http://www.adriantnt.com/products.html

Can somone please tell me how this has to be made ?

So you got to lookup
- get file contents -> http://www.php.net/file_get_contents
- find all the a tags -> http://www.php.net/preg_match
- output the found href -> http://www.php.net/echo
--
Met vriendelijke groeten,
Tim Van Wassenhove <http://www.timvw.info>
Jul 17 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

21
13045
by: John Lin | last post by:
Howdy, I want to know how to tell if a forked process is done. Actually, my real question is that I want to run a shell script inside of a python script, and after the shell script has...
2
8293
by: Richard Bell | last post by:
Newbie question ... please respond to group I'm trying to open/navigate to a url. How can I tell when the page is fully loaded? Testing suggest that window.open returns before the page is...
9
9333
by: Ian Richardson | last post by:
If I follow the steps on http://www.dhtmlcentral.com/tutorials/tutorials.asp?id=11 to add .js files to a document on demand, let's say by <body onload="blah();">, how can I reliably tell that it...
2
1616
by: Matt | last post by:
How do I tell if java script is running or enabled on the client PC? Please advise.
0
7204
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7091
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7282
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7464
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5586
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5018
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
3171
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1516
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
741
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.