Skip to content
This repository was archived by the owner on Feb 17, 2022. It is now read-only.

7.x 2.x kv

Andy Truong edited this page Mar 7, 2014 · 2 revisions
<?php
$kv = at_container('kv', 'collection_name');

// Get collection name
$kv->getCollectionName();

// Simple set
$kv->set('foo', 'bar');

// Only set if no current value at key `foo`
$kv->setIfNotExists('foo', 'baz');

// Output: bar
echo $kv->get('foo');

// Delete
$kv->delete($foo);

Clone this wiki locally