iPhone Application UUID Changes When I Update

1,083 views
Skip to first unread message

Yoh Suzuki

unread,
Feb 14, 2012, 5:05:33 PM2/14/12
to phonegap
Hello,

On the iPhone, I am copying the image taken using Camera.getPicture
into application storage so that it isn't in the temp directory. It
goes to a directory inside the following sort of path /var/mobile/
Applications/UUID/Documents/....

However, when I install over the top of my application (updating the
app so the localStorage is the same as before), the app gets a new
UUID. I no longer have access to the previous directory that my
images were saved to.

Is there a place to put my images that are more global or permanent?

Can I stop the app UUID from changing when I update?

When I get this app in the App Store, will the UUID no longer change
when I update?

Thanks!

Yoh

Shazron

unread,
Feb 14, 2012, 5:14:38 PM2/14/12
to phon...@googlegroups.com
Not quite following you - unless you store this hard-coded path
somewhere it shouldn't matter - you get the Documents directory etc
dynamically through the File API, and only store a relative path

> --
> You received this message because you are subscribed to the Google
> Groups "phonegap" group.
> To post to this group, send email to phon...@googlegroups.com
> To unsubscribe from this group, send email to
> phonegap+u...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/phonegap?hl=en?hl=en
>
> For more info on PhoneGap or to download the code go to www.phonegap.com

Yoh Suzuki

unread,
Feb 14, 2012, 5:19:37 PM2/14/12
to phon...@googlegroups.com
I'm storing the new image path so I can use the image later.  I copied it out of the temp directory where Camera.getPicture puts it, into my application documents folder.

But when I update my app, the app's UUID changes.  I no longer have access to the image because the image is in the old app's documents folder.

- y


--
Yoh Suzuki, Developer

Shazron

unread,
Feb 14, 2012, 5:24:48 PM2/14/12
to phon...@googlegroups.com
If you could read my last email again. You should only store the
relative path of the image in Documents, and get the Documents folder
path dynamically.

Yoh Suzuki

unread,
Feb 14, 2012, 5:29:14 PM2/14/12
to phon...@googlegroups.com
Oh.  You're saying that the old image will get copied over into the new app documents directory when I install over top?  - y

Shazron

unread,
Feb 14, 2012, 5:35:48 PM2/14/12
to phon...@googlegroups.com
Yes, an upgrade should preserve your Documents folder, if not there
would be angry app users everywhere if they have to recreate all their
data...

Yoh Suzuki

unread,
Feb 14, 2012, 8:27:44 PM2/14/12
to phon...@googlegroups.com
Shazron, you are the best!  Using the knowledge you dropped on me, everything works!  Thank you!  :D:D:D  - y

문성욱

unread,
Sep 14, 2015, 11:01:37 AM9/14/15
to phonegap
Hello. I just saw your email thread.

We have similar problem on our IOS APP.

We used UUID for maintaining user session for a while. But, recently, we found it changes on updating to new app version.
Because of that, our users lost their login session after updating. 

Do you know why does it change?
And do you know how we can find old UUID in new app version?

It would be really helpful, if you give me answer.

Thank you so much.

Reagards,
Moon.

Jesse Monroy

unread,
Sep 14, 2015, 9:27:28 PM9/14/15
to phonegap
@문성욱,
This thread if over 3 years old. Please start a new thread with your issue.
Thanks
Jesse

mharr

unread,
Sep 15, 2015, 1:34:27 PM9/15/15
to phonegap
Reply all
Reply to author
Forward
0 new messages