MacGapProject / MacGap1

Desktop WebKit wrapper for HTML/CSS/JS applications.
Other
3.55k stars 208 forks source link

including sqlite for webapp #16

Closed ChadStrat closed 12 years ago

ChadStrat commented 12 years ago

Hi, I love this! thanks for working on it!

I was able to nicely port my webapp (html5 & js files) using macgap...but sadly it doesn't include/recognize sqlite.

I tried simply including the sqlite3 lib, but no joy.

I'm not real "xcode" savy, and was wondering if you/someone could share how to do this?

Sorry to post here...I wasn't sure were to find help relating macgap and sqlite.

thanks in advance!

ChadStrat

maccman commented 12 years ago

There was a recent fix for this on master, try using that.

Does localStorage work for you? If it does, then sqlite may just be another flag that I need to enable in the preferences.

ChadStrat commented 12 years ago

not really. I have several tables with local data that gets synced to a remote server, but can fully function locally.

Thanks for checking into it!

ChadStrat

maccman commented 12 years ago

So, let me confirm, are you using localStorage or WebDB? Are you using master and re-compiling?

ChadStrat commented 12 years ago

webDB or more specifically sqLite.

re: http://html5doctor.com/introducing-web-sql-databases/

ChadStrat

maccman commented 12 years ago

Ok, so does this work:

alert(localStorage['test']) localStorage['test'] = 1

ChadStrat commented 12 years ago

it does. but I need a query-able data set. string data will not be very helpful for my particular application. I tried adding in the sqlite3.lib framework..but I clearly am missing something in making it accessible within the app.

ChadStrat commented 12 years ago

Hey that commit worked great man! rock on! my app looks and functions native and it's all HTML5 CSS3 JS & SQLite. very, VERY cool. thanks so much! so you have a site or company I can give credit to in my app?