[Qt-qml] Arbitrary OfflineStorage paths

Mark Constable markc at renta.net
Fri Nov 18 07:04:42 CET 2011


On 2011-11-18 12:01 PM, Alan Alpert wrote:
> > Would it be possible to expand the first argument below to allow
> > for dealing with arbitrary paths?
> > 
> > ie; if the first argument started with "/" or "./" then it would
> > be treated as an absolute or relative path to the db. Use case is
> > obviously interacting with HTML5 or system installed databases.

s/HTML5/HTML/

> How does HTML5 deal with this usecase? Presumably opening arbitrary
> databases for online storage is a security risk, does HTML5 storage
> have an answer for this?

HTML5 implies browser specific localstorage whereas I really meant
simply interacting with web based (LAMP-like) systems, or any other
application. In particular, I have an embedded device with lighttpd
and PHP in plain CGI mode with various apps all using Sqlite3 dbs
(very low memory use) and I'd like to enable local QML gui apps to
read/write to the same databases, with suitable SQL locking.

ATM I have to create dummy databases in...

~/.local/share/data/Nokia/QtQmlViewer/QML/OfflineStorage/Databases/*

and use a clumsy shell script to find the right ones and symlink them
to the "real" databases used by the various web apps.


More information about the Qt-qml mailing list