×

Discussion Board

Results 1 to 9 of 9
  1. #1
    Registered User
    Join Date
    Dec 2009
    Posts
    6

    Question Taking a picture and uploading it to a J2ee Server

    Hello,
    I'm trying to take a picture using the APIBridge and the example APIBridgeTest.
    As a widget the example starts the camera, but when I insert the code to my own J2ee project and displaying it as a web page in my mobile the APIBridge doesn't work...

    I'm trying to go in 2 directions -
    1. Make my widget display the content of my J2ee web page with the functunallity of starting the camera (and after uploading the binary data).
    2. Surf through the web to my J2ee web page and starting the camera....

    Which way is better? Is it even possible?
    Thanks in advance...

  2. #2
    Nokia Developer Champion
    Join Date
    Nov 2007
    Location
    Rome, Italy
    Posts
    2,406

    Re: Taking a picture and uploading it to a J2ee Server

    Hi Mitchkado,

    welcome to Forum Nokia Discussion Boards!

    I'm not sure I've clearly understood your questions, anyway in the scenario you describe the usual process is:

    * the widget, by using API Bridge, takes the picture and uploads it to your web server
    * the web server receives and handles the received picture, saving it somewhere

    So, the Web server is usually only responsible for handling the received picture.

    If you also need to display data sent from the Web server, you may want to use XMLHttpRequest objects and a suitable data format (XML or JSON).

    Please let me know if I've missed something in your question
    Pit

  3. #3
    Registered User
    Join Date
    Dec 2009
    Posts
    6

    Re: Taking a picture and uploading it to a J2ee Server

    Hi jappit,
    First thanks for the quick reply...
    Second, Is it possible to use the api bridge without the widget (I want my to display a web page with the functunallity of the api bridge)?

    Can you share an example of using api bridge this way?

  4. #4
    Nokia Developer Champion
    Join Date
    Nov 2007
    Location
    Rome, Italy
    Posts
    2,406

    Re: Taking a picture and uploading it to a J2ee Server

    Hi Mitchkado,

    so, you want to display a mobile web page that starts and uploads a picture taken from the mobile camera itself?

    Pit

  5. #5
    Registered User
    Join Date
    Dec 2009
    Posts
    6

    Re: Taking a picture and uploading it to a J2ee Server

    Yes, on a javascript ver 1.0

  6. #6
    Nokia Developer Champion
    Join Date
    Nov 2007
    Location
    Rome, Italy
    Posts
    2,406

    Re: Taking a picture and uploading it to a J2ee Server

    As far as I've seen, there's not a ready-to-use solution to achieve this, for different reasons:

    * the API Bridge engine must be installed on the mobile device: you can easily deploy it together with a widget, but there's no such an easy mechanism to do the same from a Web page (e.g.: you cannot check if it is already installed from a web page)
    * the API Bridge JavaScript library relies on some WRT functionalities and objects, so it will not work outside the widget environment
    * API Bridge performs local HTTP calls, that are possible since widgets have a particular security policy that allows them to access any domains. This is not true (afaik) for mobile web pages.

    So, I would say that it's currently not possible, or at least not without any tweaks
    Pit

  7. #7
    Registered User
    Join Date
    Dec 2009
    Posts
    6

    Re: Taking a picture and uploading it to a J2ee Server

    OK, I'm starting to get the picture...
    Is it possible to create a widget that check every time it loads if a newer version of this widget exist on a predefined server and if so to install it? (with as little user intervention as possible).

  8. #8
    Nokia Developer Champion
    Join Date
    Nov 2007
    Location
    Rome, Italy
    Posts
    2,406

    Re: Taking a picture and uploading it to a J2ee Server

    Sure, check out this Wiki article:

    http://wiki.forum.nokia.com/index.ph...ng_WRT_widgets

    Hope it helps,
    Pit

  9. #9
    Registered User
    Join Date
    Dec 2009
    Posts
    6

    Re: Taking a picture and uploading it to a J2ee Server

    Great!
    Thanks for all your help!

Similar Threads

  1. N96 device reboots when taking picture
    By Larsson73 in forum Symbian Media (Closed)
    Replies: 1
    Last Post: 2009-06-11, 09:00
  2. Taking a picture through Python and working on it in c++
    By pdcb_pdcb in forum Symbian Media (Closed)
    Replies: 6
    Last Post: 2007-11-21, 18:16
  3. Audio is heard while taking picture
    By arunnrnair in forum Symbian Media (Closed)
    Replies: 3
    Last Post: 2007-10-01, 13:00
  4. Sending Sms from a J2ee server
    By vikki_vikki in forum General Messaging
    Replies: 1
    Last Post: 2004-02-24, 14:03
  5. Previewing a picture before taking
    By evellasques in forum Symbian
    Replies: 1
    Last Post: 2004-02-05, 09:20

Posting Permissions

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