×

Discussion Board

Results 1 to 3 of 3

Threaded View

  1. #1
    Registered User
    Join Date
    Mar 2009
    Posts
    1

    Using iframe for photo upload

    I'm developing a widget which should do photo uploads. After a successful upload the widget should display the newly uploaded photo.

    Photos are uploaded using HTTP POST to a REST API. The API will (only) return a XML file containing an atom feed of the uploaded photos. I'd like to read the XML file, parse the URL of the uploaded photo and display it to the user.

    I'm currently using an iframe to upload the photo. This way I can keep the user on the upload page until the upload is ready. I'm using jQuery to listen when the iframe has finished loading the XML:
    Code:
    $('#fileUploadFrame').load(function() { ... });
    The trouble is, I can't get the contents of that XML. I've tried for example:

    Code:
    var xml = document.getElementById('fileUploadFrame').contentWindow.document;
    Is there a way to read the iframe's content? Or is there some better way to handle file uploads with or without iframes?


    Thank you for your answers.
    Last edited by oiva; 2009-03-02 at 09:37.

Similar Threads

  1. HTTP POST - Upload multiple files
    By bgenady in forum Symbian Networking & Messaging (Closed)
    Replies: 4
    Last Post: 2009-01-21, 01:49
  2. Replies: 3
    Last Post: 2006-05-02, 20:12
  3. Where can I upload an Appication?
    By Borriez in forum General Development Questions
    Replies: 0
    Last Post: 2005-09-20, 15:36
  4. upload J2ME app onto Java phones
    By mzichao in forum Mobile Java General
    Replies: 1
    Last Post: 2005-01-11, 07:11

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×