Find Jobs
Hire Freelancers

curl multi update

$10-30 USD

Đã hủy
Đã đăng vào gần 10 năm trước

$10-30 USD

Thanh toán khi bàn giao
I need updates to a curl function, which is ATTACHED: Current function is passed array of url's and uses curl multi to download and save page to file. My webserver can handle 250 curl requests at once. If you want to rewrite function, is ok as long as it does what it currently shows and the new items below. Basically needs to receive urls and etag or last modified date and save page if newer than last etag or last modified data or update db with error code if [login to view URL] items below, I need the error code or date or etag etc to be in a variable somehow so that I can insert it into database using id field. Just insert comment before and after where need to insert mysqli statement and show what the variable is called (probably obvious but maybe not) like //insert mysqli here to update etag or last_modified date when newer than what is in database //$http_code //is the variable to return the error code if an error exists for a specific url request //$etag //is the variable to return the current etag //end of insert mysqli I need the following added to the function: 0. function currently receives array of id=>url, instead needs to pass following fields in row from query result (id,url,etag,last_modified). 1. before it creates new file, check to see if error from header if > 400 code, should not create file and should give code to update database and fclose if fopen was used, don't save page and close everything for this url. If bad request like bad url etc, must do same thing except return error code. Also if ($content_length == 0) should return error "99999". 2. Read header info and if ETag == $db['etag'] don't save page and close everything for this url. if !ETAG then if Last-Modified == $db['last_modified'] don't save page and close everything for this url. 3. at end of script before it returns from last item in array needs to update database to change satus so just put mysqli comment block for it. 4. Add to enable http proxy as option, I will probably just use one version for db_result that don't need proxy and then one version for db_result that requires proxy and sleep(15) if from same host; comment this entire block so I know what to comment out for db_result where no proxy required. 5. set options as an array instead of individual curl_setopt if possible, add cookiefile => cookie.txt. Needs to handle https also. max_redirects 3,
Mã dự án: 6078412

Về dự án

4 đề xuất
Dự án từ xa
Hoạt động 9 năm trước

Bạn muốn kiếm tiền?

Lợi ích khi chào giá trên Freelancer

Thiết lập ngân sách và thời gian
Nhận thanh toán cho công việc
Phác thảo đề xuất của bạn
Miễn phí đăng ký và cháo giá cho công việc
4 freelancer chào giá trung bình $184 USD cho công việc này
Avatar người dùng
Hi I work towards providing reliable, relevant and robust IT solutions at most competitive prices to my customers. I ensure 100% customer satisfaction so lets start Thanks
$206 USD trong 7 ngày
4,9 (210 nhận xét)
7,5
7,5
Avatar người dùng
Hi, I'm an expert about PHP. I have read your project and confident that can handle this. Please give me more detail about the project then I can make a demo for you. Please feel free to discuss with me. Best regards, Mr New
$388 USD trong 5 ngày
5,0 (36 nhận xét)
5,7
5,7
Avatar người dùng
Hi, Did some scrappers with curl and i can help you with this one. Hope to collaborate on this. Thanks.
$35 USD trong 1 ngày
0,0 (0 nhận xét)
0,0
0,0

Về khách hàng

Cờ của UNITED STATES
Portland, United States
4,3
7
Phương thức thanh toán đã xác thực
Thành viên từ thg 5 14, 2013

Xác thực khách hàng

Cảm ơn bạn! Chúng tôi đã gửi email chứa đường link để bạn lấy tín dụng miễn phí.
Đã xảy ra lỗi trong khi gửi email của bạn. Hãy thử lại.
Người Dùng Đã Đăng Ký Tổng Số Việc Đã Đăng
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Đang tải xem trước
Đã cấp quyền truy cập vị trí.
Phiên đăng nhập của bạn đã hết hạn và bạn đã bị đăng xuất. Hãy đăng nhập lại.