Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7089691
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T07:57:11+00:00 2026-05-28T07:57:11+00:00

I am writing a PhoneGap application to work on Android initially. I am writing

  • 0

I am writing a PhoneGap application to work on Android initially.

I am writing it to collect images from the camera and store them in the database (a SQLite database using the HTML5 functionality for databases).

So there are two options, store the images in the database, and store the images on the SD card and reference them by filename.

So storing them on the SD card, how can I stop someone deleting them? I can’t right, I mean they could remove the SD card too.

Storing them in the database, the HTML5 spec suggests that databases shouldn’t be bigger than 5 MB, and if they are then the user will be asked if they want to increase the size. But perhaps this is not really an issue for a PhoneGap app?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T07:57:12+00:00Added an answer on May 28, 2026 at 7:57 am

    My recommendation is to store the images as files on the file system. After you take the picture it will be on the SD Card but then you use the File API to move the images to /data/data/{app package name}. That directory is protected and the user is very unlikely to delete the files in that sandbox. It also has the added bonus that when your application is uninstalled that the directory is cleaned up.

    This will get you around a host of issues with taking a picture and returning Base64 data. On a lot of phones the camera is so good that the base64 encoded string causes an out of memory error so I tell people to avoid the DATA_URL option whenever then can. Plus, now you store a lot less data in your DB and won’t run into size limits quite so easily.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am writing an application using PhoneGap, and am finding it hard to work
I am writing application using PhoneGap on Android. I need to call some PhoneGap
I'm writing an application in PhoneGap that I want to run on iOS, Android,
I am developing a PhoneGap application for Android (will work on iOS too). The
I'm writing an HTML5 mobile application, and using PhoneGap to push it to the
I am writing a iphone application using phonegap and ios. I have a weird
I am writing a native iPhone and Android app using Sencha Touch inside Phonegap
I'm writing a website/iPad app (using PhoneGap ), where I have 1024x768 images on
I'm currently writing an application using Zepto and phonegap, and I need to know
I'm currently writing a mobile app (hopefully iOS or android) using the jquery mobile

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.