1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

PHP Programmer Seeks Genuis Javascript Programmer for Quick Job

Discussion in 'Other Languages' started by soma56, May 16, 2014.

  1. soma56

    soma56 Regular Member

    Joined:
    Jun 16, 2009
    Messages:
    276
    Likes Received:
    154
    Home Page:
    I'm creating a script that posts a form. I have no issues logging into the server, via cURL, and doing what I need to do. However, there is an option to browse and select a photo that can be included. Is there such a way to easily do this in Javascript? The remote input on the server would be something this:

    <input type="file" name="photo" id="photo" value=""/>

    Very basic, as you can see. How can I automatically assign a value of a photo (let's assume it's on another server) to this input box?
     
  2. soma56

    soma56 Regular Member

    Joined:
    Jun 16, 2009
    Messages:
    276
    Likes Received:
    154
    Home Page:
    Nevermind, I figured out a more effective way to do this. And it works!