# content-control/trunk/classes/Base/Container.php

Content Control – The Ultimate Content Restriction Plugin! Restrict Content, Create Conditional Blocks &amp; More, version trunk. 43 lines.

- Page: https://pluginprobe.com/plugins/content-control/trunk/code/classes/Base/Container.php
- Raw: https://pluginprobe.com/plugins/content-control/trunk/raw/classes/Base/Container.php
- Modified: 2023-09-21T10:13:04+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/content-control/trunk/code/classes/Base/Container.php#L10-L20`.

```php
<?php
/**
 * Plugin container.
 *
 * @copyright (c) 2021, Code Atlantic LLC.
 *
 * @package ContentControl
 */

namespace ContentControl\Base;

defined( 'ABSPATH' ) || exit;

use ContentControl\Vendor\Pimple\Container as Base;

/**
 * Localized container class.
 */
class Container extends Base {
	/**
	 * Get item from container
	 *
	 * @param string $id Key for the item.
	 *
	 * @return mixed Current value of the item.
	 */
	public function get( $id ) {
		return $this->offsetGet( $id );
	}

	/**
	 * Set item in container
	 *
	 * @param string $id Key for the item.
	 * @param mixed  $value Value to be set.
	 *
	 * @return void
	 */
	public function set( $id, $value ) {
		$this->offsetSet( $id, $value );
	}
}

```
