I have a problem in my code. I parse web pages finding usfull information. But very usually there are bad servers on the net. They work slowly, and loading page of several kb takes up to minute or can take more.
So i am using file($where) where $where is page address.
So is there any way to interrupt this function if time exeeds some limit? or any other method to load page with ability to control the time!
How to interrupt native function in php
Moderator: General Moderators
-
dark_religion
- Forum Newbie
- Posts: 3
- Joined: Sat Dec 06, 2008 3:00 am
Re: How to interrupt native function in php
If you want more control over how you retrieve information over the web, use something like cURL instead.
-
dark_religion
- Forum Newbie
- Posts: 3
- Joined: Sat Dec 06, 2008 3:00 am
Re: How to interrupt native function in php
and it can stop loading page if it is loading slowly?