sfDoctrineActAsKeyValueStorePlugin is a Doctrine behavior that lets
you store additional attribute values along with any Doctrine object
without the need for a schema change. Data is stored and retrieved
with very low overhead. Great for incidental information, like "this
user has already seen the welcome screen."

Example:

# in schema.yml
sfGuardUser:
  actAs: [KeyValueStore]

$user = // fetch your user with a normal Doctrine query
// Stash some extra data
$user->aSet('seen_welcome', true);
$user->save();

$user = // Later, fetch the object again
// Get our attribute back, with a default
$user->aGet('seen_welcome', false);

For more information see:

http://trac.apostrophenow.org/wiki/sfDoctrineActAsKeyValueStorePlugin

You do not need Apostrophe to use this plugin.

Cheers!

-- 
Tom Boutell
P'unk Avenue
215 755 1330
punkave.com
window.punkave.com

-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony users" group.
To post to this group, send email to symfony-users@googlegroups.com
To unsubscribe from this group, send email to
symfony-users+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/symfony-users?hl=en

Reply via email to