Basic Question about Threading and PHP...


Posted on 16th Feb 2014 07:03 pm by admin

I have a page that I am working on and it is taking several hours to process. The basics of what the page does is get all the items out of a database then with cURL download some HTML parse through it and if anything has changes update values back in the database. 90% of the time is spent waiting on libcurl to download the page and the page is VERY low on CPU usage. In the effort of trying to speed things up I thought about trying to thread the download process, but from a quick google search it appears that PHP lacks Threading support. Does anyone know of anything that could be done to speed things up? Maybe something I missed with cURL that would make it download faster or an alternative to Threading?

Thanks

No comments posted yet

Your Answer:

Login to answer
125 Like 42 Dislike
Previous forums Next forums
Other forums

Will an XHTML DOCTYPE interfere with my PHP if I'm not experienced enough?
I've read this article here: http://friendlybit.com/html/why-xhtml-is-a-bad-idea/

In a nutshe

get multiple rows
Hi I want to get multiple rows from a db

I am using this for the db query
Code: public

Just a white page
Okay so, my website, when I click SignUp on it it takes me to /join.php but its a complete white pag

Add 5 to a variable when a button is clicked, and re-run a for loop
So I'm making a feedback sort of section on a website with MySQL and PHP, I've gotten the script to

Alternate messaging
I have 4 strings in MySQL db1

$string1 : Hello
$string2 : Hi
$string3 : Great
$strin

Download Image from URL and Upload it
Ok, I have been googling for the last 1/2 hour trying to figure this out, Most likely I'm just not s

Inserting 100x and 100y coordinates in mysql table - easy
Is there a way to insert this data into a mysql table named 'map' with the fields: 'x int 3' , 'y in

PHP search multiple input field box help
I am having a problem with my search script. At current it will simply search by a selected date whi

error with opendir
when i do this

if ($handle = opendir($dir)) {
while (false !== ($file = readdir($han

Multiple Do / While Statements?
I'm still very new to PHP, and running in to a problem when trying to execute a do/while loop inside

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash