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 getUserAllInfoById($id) { | |
$select = new Select($this->table); | |
$select->where->equalTo('id', $id); | |
return $this->selectWith($select)->toArray(); | |
} | |
in controller... | |
public function indexAction() { |
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
'router' => array( | |
'routes' => array( | |
'home' => array( | |
'type' => 'Zend\Mvc\Router\Http\Literal', | |
'options' => array( | |
'route' => '/', | |
'defaults' => array( | |
'controller' => 'Application\Controller\Index', | |
'action' => 'index', | |
), |
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
'router' => array ( | |
'routes' => array ( | |
'ajax' => array ( | |
'type' => 'Segment', | |
'options' => array ( | |
'route' => '/ajax[/:action]', | |
'constraints' => array ( | |
'action' => '[a-zA-Z][a-zA-Z0-9_-]*', | |
), | |
'defaults' => 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 | |
/** | |
* Zend Framework (http://framework.zend.com/) | |
* | |
* @link http://github.com/zendframework/ZendSkeletonApplication for the canonical source repository | |
* @copyright Copyright (c) 2005-2013 Zend Technologies USA Inc. (http://www.zend.com) | |
* @license http://framework.zend.com/license/new-bsd New BSD License | |
*/ | |
return array ( | |
'router' => 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 | |
/* | |
* To change this template, choose Tools | Templates | |
* and open the template in the editor. | |
*/ | |
namespace Application\Model; | |
use Zend\Db\Adapter\Adapter; |
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
// Module.php | |
public function getAutoloaderConfig() | |
{ | |
return array( | |
'Zend\Loader\ClassMapAutoloader' => array( | |
__DIR__ . '/autoload_classmap.php', | |
array( | |
'Facebook' => 'vendor/facebook/php-sdk/src/facebook.php', | |
'Paypal' => 'vendor/paypal/lib/PayPal/AdaptivePayments/' |
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 | |
if (!isset($this->og_title)) { | |
$this->og_title = $this->translate('esolidar titulo'); | |
} | |
$this->headMeta() | |
->prependName('viewport', 'width=device-width') | |
->prependHttpEquiv('X-UA-Compatible', 'IE=edge') | |
->prependHttpEquiv('X-Frame-Options', 'DENY') | |
->setName('description', $this->translate('A esolidar é um mercado online solidário. Compra, vende, partilha e contribui para um mundo melhor.')) | |
->setProperty('fb:app_id', $this->Config()['facebook']['api_id']) |
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
In controller: | |
$job = new \Application\Job\EmailJob(); | |
// Get the queue plugin manager | |
$queueManager = $this->serviceLocator->get('SlmQueue\Queue\QueuePluginManager'); | |
$queue = $queueManager->get('teste'); | |
$queue->push($job, array( | |
'priority' => 20, |
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
use PayPal\Service\AdaptivePaymentsService; | |
use PayPal\Types\AP\Receiver; | |
use PayPal\Types\AP\ReceiverList; | |
use PayPal\Types\AP\PayRequest; | |
use PayPal\Types\Common\RequestEnvelope; | |
use PayPal\Service\AdaptiveAccountsService; | |
use PayPal\Types\AA\AccountIdentifierType; | |
use PayPal\Types\AA\GetVerifiedStatusRequest; |
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 getControllerPluginConfig() | |
{ | |
return array( | |
'factories' => array( | |
// call this key zmPlugin in your action controller | |
'emailsPlugin' => function ($sm) | |
{ | |
$emailPluginController = new \Application\Controller\Plugin\EmailsPluginController(); | |
$emailPluginController->setServiceManager($sm); | |
return $emailPluginController; |
OlderNewer