×

Discussion Board

Results 1 to 7 of 7
  1. #1
    Registered User
    Join Date
    Jan 2007
    Location
    bucharest
    Posts
    222

    can a external widget access local files?

    ok, I have a widget which has
    Code:
    <META http-equiv="REFRESH" content="0; url=http://....">
    how do I access the local files? from that http? i've tried with "E:/myFolder/image.jpg" and "file:///E:/myFolder/image.jpg" but is no working...

    or it's from security?

  2. #2
    Regular Contributor
    Join Date
    Mar 2006
    Posts
    83

    Re: can a external widget access local files?

    Try using relative paths ("myFolder/image.jpg").
    This works without issues.


    Best regards

    Dusan

  3. #3
    Registered User
    Join Date
    Jan 2007
    Location
    bucharest
    Posts
    222

    Re: can a external widget access local files?

    the HTML and SWF are on the server! so if I put "myFolder/image.jpg" it will look at http://www.mydomain.com/myFolder/image.jpg

    just wanna do a photoViewer widget, that will constantly updating the functions, so that the user don't have to reinstall the app again

    Quote Originally Posted by powerpixels View Post
    Try using relative paths ("myFolder/image.jpg").
    This works without issues.


    Best regards

    Dusan

  4. #4
    Registered User
    Join Date
    Mar 2010
    Location
    Zaandam, Holland
    Posts
    71

    Re: can a external widget access local files?

    Try creating an auto-update function to your widget instead.

    In the init function, put an ajax call to fetch (updated) script from your server,
    write it away using setPreferenceForKey, and add the script element to your local
    project.

    Google "auto update wrt widgets" for loads of examples.

  5. #5
    Registered User
    Join Date
    Jan 2007
    Location
    bucharest
    Posts
    222

    Re: can a external widget access local files?

    just tested, the HTML sees both "e:/myFolder/image.jpg" and "file:///e:/myFolder/image.jpg"

    just the swf inside the html won't see it...

    the way I see it is I put the HTML in the widget and .js and swf on server... and should work...

  6. #6
    Regular Contributor
    Join Date
    Mar 2006
    Posts
    83

    Re: can a external widget access local files?

    Maybe it's because of security limits and flash that is loaded to cache. I have no clue what are you going to do with local jpg images, but I believe it can be done without flash, using js and workarounds
    Best regards,
    Dusan

  7. #7
    Registered User
    Join Date
    Jan 2007
    Location
    bucharest
    Posts
    222

    Re: can a external widget access local files?

    this is what I'm doing: http://m.ilook.ro/?id2=0000

    because save function (sharedObjects got only 4K, and is to low for my app, about 32-64K I need); in WRT i've tested and got 128K and more space to save (with widget.setPreferenceForKey)

    so, no, there is no workaround with js

    Quote Originally Posted by powerpixels View Post
    Maybe it's because of security limits and flash that is loaded to cache. I have no clue what are you going to do with local jpg images, but I believe it can be done without flash, using js and workarounds

Similar Threads

  1. Replies: 4
    Last Post: 2010-01-25, 09:29
  2. Dailogs and his features
    By MobiSecLap in forum Symbian C++
    Replies: 18
    Last Post: 2009-02-10, 13:27
  3. Access Point Connection Problem on N96... Help!
    By asenechalM5T in forum Symbian Networking & Messaging (Closed)
    Replies: 4
    Last Post: 2008-11-17, 15:00
  4. CPbkContactEditorDlg customize
    By asdfghjkl_asdfghjkl in forum Symbian C++
    Replies: 5
    Last Post: 2008-08-05, 02:56
  5. help for porting
    By sjyuhusun in forum Symbian
    Replies: 10
    Last Post: 2007-06-05, 03:44

Posting Permissions

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