Example source code available from that ants thing.

P5 source: http_post.zip
PHP source: upload.phps


7 Responses to “Create JPG and upload to web server from Processing”  

  1. 1 jesús gollonet

    yum! I was about to ask you for that as I have to do something similar. Thanks very much!

  2. 2 jesús gollonet

    btw, i’m trying to open the http_post.zip but i can’t. It seems to be corrupted. Could you check it, please?

    Thanks again

  3. 3 Daniel

    Ooops, thanks, fixed now!

  4. 4 A_Flama

    Very nice!!! I’m gonna try that :D
    Thank you!!!

  5. 5 Mike Shaub

    This looks great! I have the source and would like to try out the program. I am so unfamiliar with server paths and PHP though that I’m not able to setup the directories properly. Could you please explain (iike I’m 5 years old) what folders I should setup on my server? I do know about setting permissions, but the relative folders and where slashes should and shouldn’t go seems to escape me. in your PHP there are 2 paths:
    $uploaddir = ‘/home/whatever/’;

    $uploadrelativefile = ‘http://www.whatever.net/whatever/’ . $uploadfilename;

    and in the sketch there this:
    String url = “http://www.mydownain.com/myphp.php”

    Could you explain where the processing sketch goes, the folder for uploaded images, and the php script? Thanks, this is pretty nice.

  6. 6 Daniel

    $uploaddir = ‘/home/whatever/’;

    The above is the folder you want to upload the files to using the real server path.

    $uploadrelativefile = ‘http://www.whatever.net/whatever/’ . $uploadfilename;

    The above is the URL path to the file, i.e. what you would type into a browser to see it. These two paths depend on your server configuration.

    and in the sketch there this:

    String url = “http://www.mydownain.com/myphp.php”

    This is the path to where you put your PHP code, again what you would type in the browser to find it.

  1. 1 thedemos » Blog Archive » Create JPG and upload to web server from Processing


Leave a Reply