This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @author Marco Pivetta <[email protected]> | |
*/ | |
use Zend\ServiceManager\ServiceManager; | |
use Zend\Mvc\Service\ServiceManagerConfig; | |
use DoctrineORMModuleTest\Framework\TestCase; | |
use ContentTest\Util\ServiceManagerFactory; | |
use Zend\Loader\StandardAutoloader; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* File: main.cpp | |
* Author: Fabio | |
* | |
* Created on July 22, 2013, 9:52 PM | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function getFreightForm() { | |
$form = new Form(); | |
$items = $this->session->offsetGet('list'); | |
foreach ($items as $i => $consumer) { | |
$fieldset = new Fieldset($i); | |
foreach ($consumer->getItems() as $token => $item) { | |
$fieldset->add(array( | |
'type' => 'text', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class cart { | |
public $item; | |
public function getItem() { | |
return $this->item; | |
} | |
public function setItem(&$item) { | |
$this->item = $item; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Cart; | |
use Zend\Mvc\ModuleRouteListener; | |
use Zend\Mvc\MvcEvent; | |
class Module | |
{ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Zend\Form\Fieldset; | |
use Zend\Form\Form; | |
use Zend\Form\View\Helper\Form as FormHelper; | |
use Zend\Form\View\HelperConfig; | |
use Zend\Stdlib\ArrayUtils; | |
use Zend\Stdlib\Hydrator\ObjectProperty; | |
use Zend\View\Renderer\PhpRenderer; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- element -- | |
string 'Cart\Form\ProductFieldset' (length=25) | |
-- object -- | |
object(Product\Entity\Product)[539] | |
protected 'id' => int 31 | |
protected 'sku' => string 'PH043' (length=5) | |
protected 'name' => string 'FONE COM MICROFONE USB DIGITAL PC / PLAYSTATION 3' (length=49) | |
protected 'slug' => string 'fone-com-microfone-usb-digital-pc-playstation-3' (length=47) | |
-- hydrator target class -- | |
string 'Product\Entity\Product' (length=22) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function addAction() | |
{ | |
$album = new Album; | |
$form = new AlbumForm($this->getEntityManager()); | |
$form->setHydrator(new DoctrineEntity($this->getEntityManager(),'Admin\Entity\Album')); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function extract() | |
{ | |
if ($this->object instanceof Traversable) { | |
$this->object = ArrayUtils::iteratorToArray($this->object, false); | |
} | |
if (!is_array($this->object)) { | |
return array(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Router { | |
protected $routes = array(); | |
protected $namedRoutes = array(); | |
protected $basePath = ''; | |
protected $matchTypes = array( | |
'i' => '[0-9]++', | |
'a' => '[0-9A-Za-z]++', |
OlderNewer