Home > PHP > Remote Upload To Imageshack.Us With PHP+cURL

Remote Upload To Imageshack.Us With PHP+cURL


Advertisement



PHP supports libcurl since V 4.0.2, a library created by Daniel Stenberg (more information go here), that allows you to connect and communicate to many different types of servers with many different types of protocols. libcurl currently supports the http, https, ftp, gopher, telnet, dict, file, and ldap protocols. libcurl also supports HTTPS certificates, HTTP POST, HTTP PUT, FTP uploading (this can also be done with PHP’s ftp extension), HTTP form based upload, proxies, cookies, and user+password authentication.

Now with cURL we trying to make a script that post images to Imageshack.Us via remote upload and return direct link of images. Here the source code to download.

Update Scipt! Please download new version – 20 December 2009.

Download Code

Pass : smileylover.com

This script should work and return direct link of images that being upload. If the result is empty (error with cURL) it will return Something went wrong with Imageshack?, but if result is empty for preg_match_all function it will return Imageshack.Us Remote Upload Failed Because They Change Layout Again! and send email to your email. Just announcement.

Usually, there’s an error with preg_match_all because Imageshack.Us is change their HTML tag regularly (i think) to avoid script like this (Hey with this script same with block their ads :p ). If an error occurs just come back to here to get update with working script.

DEMO

Regards.

nb: i prefer imageshack.us because they have a lot of bandwith. they allow us to use their bandwith 300MB/hour per single image!

Related posts:

  1. Text2Image (PNG) Generator – Free Online Generator – Free Download!
  2. Change Adsense Publisher ID In Other Site With PHP and cURL
  1. August 31st, 2008 at 03:53 | #1

    sorry, but … password for the .zip file? :)

  2. Admin
    August 31st, 2008 at 17:46 | #2

    Pass is smileylover.com

    I’m sorry forget to include it :)

    Thnx

  3. Why must always rapidshare??
    September 29th, 2008 at 13:31 | #3

    direct link plizz…

    i hate rapidshare !!
    I can’t download in rapidshare guys… :(

  4. Admin
    September 29th, 2008 at 17:57 | #4

    Btw the file size is so small .. u can use rapidshare.info.tm to download it :)

    i’m sorry for do this bcoz BW problem.

    thnx

  5. October 5th, 2008 at 06:33 | #5

    Nice. Thanks.

  6. October 13th, 2008 at 05:17 | #6

    Hi!
    My name is Jessika!

  7. October 17th, 2008 at 03:56 | #7

    nice info bro, thanks!

  8. November 11th, 2008 at 15:29 | #8

    hi,
    it gives me that error!

    “Warning! Image type not valid or supported.”

    how to fix this?
    thanks

  9. Admin
    November 11th, 2008 at 18:27 | #9

    @ameo

    its seems ur hosting problem ….

    if u want free hosting that worked with this script .. try freehostia.com :)

    they have enable cURL and open base dir function :D

    regards

  10. November 11th, 2008 at 18:48 | #10

    hmm, Thanks for the suggestion, but i’m happy with my host so far :)

    Thanks

Comment pages
1 2 3 4 15
  1. No trackbacks yet.