Database abstraction #8

Open
wants to merge 104 commits into
from

Conversation

Projects
None yet
2 participants
@rmccue
Contributor

rmccue commented Mar 3, 2012

Change all the classes which use DataHandler to use a new database abstraction instead.

This tracks the status of the conversion.

rmccue added some commits Dec 10, 2011

Ignore the `feed` property and throw Exceptions from __set
If it's a property that isn't public or known, we need to throw an Exception, not just continue.
Let objects specify a _db_export method
Some objects (like Lilina_Item) will need to export non-public properties, for use later via __set(). If the _db_export method exists, that will be called instead of get_object_vars.

rmccue added some commits Jan 7, 2012

Fix sprintf, again
Not sure how, but I undid this somewhere.
Forget about all the complicated adapter stuff and just upgrade.
Instead of having different adapters lying around, move everything in an upgrade instead.
Fix some errors in the DB classes
Don't worry, the filters here will be returning in a different form later.
Move all bootstrapping into Lilina::bootstrap()
Also allow for DB setting in settings.php
Don't load options in conf.php
We'll end up replacing this file completely.
Actually add the adapter too.
💡 "Hey, wouldn't that be a good idea?"
Escape WHERE keys
There's a vulnerability here, but a WHERE's key is trusted data.
@rmccue

This comment has been minimized.

Show comment Hide comment
@rmccue

rmccue Mar 3, 2012

Contributor

Still needs an OR type for the WHERE. Might be worth trying to build a proper parser for this, not sure yet.

Contributor

rmccue commented Mar 3, 2012

Still needs an OR type for the WHERE. Might be worth trying to build a proper parser for this, not sure yet.

@xxxazxxx

This comment has been minimized.

Show comment Hide comment
@xxxazxxx

xxxazxxx Aug 17, 2012

does this work?
i tried installing it but i get an error

( ! ) Fatal error: Call to a member function update() on a non-object in C:\xampp\htdocs\lilinan\Lilina\inc\core\Options.php on line 116
Call Stack

Time Memory Function Location
1 0.0015 379704 {main}( ) ..\install.php:0
2 0.0097 613672 Installer->install( ) ..\install.php:112
3 0.0178 678032 Options::save( ) ..\install-functions.php:66
4 0.0179 678080 Options::update( ) ..\Options.php:147

does this work?
i tried installing it but i get an error

( ! ) Fatal error: Call to a member function update() on a non-object in C:\xampp\htdocs\lilinan\Lilina\inc\core\Options.php on line 116
Call Stack

Time Memory Function Location
1 0.0015 379704 {main}( ) ..\install.php:0
2 0.0097 613672 Installer->install( ) ..\install.php:112
3 0.0178 678032 Options::save( ) ..\install-functions.php:66
4 0.0179 678080 Options::update( ) ..\Options.php:147

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment