Skip to content

Instantly share code, notes, and snippets.

View jonathanmaron's full-sized avatar

Jonathan Maron jonathanmaron

View GitHub Profile
use Zend\Soap\Client\Client;
use Zend\Debug;
$endpoint = 'http://invald.example.com/missing.wsdl';
try {
$client = new Client();
$client->setWsdl($endpoint);
} catch (SoapFault $e) {
Debug::dump($e->getMessage());
use Zend\Soap\Client\Client;
use Zend\Debug;
$endpoint = 'http://invald.example.com/missing.wsdl';
try {
$client = new Client();
$client->setWsdl($endpoint);
$client->LogIn(array('username' => 'invalid', 'password' => 'invalid'));
} catch (\SoapFault $e) {
use \Zend\Validator\VATIN;
// syntax only check
$validator = new VATIN();
$validator->isValid('XX0000000000');
PHP 5.3.2-1ubuntu4.5 with Suhosin-Patch (cli) (built: Sep 17 2010 13:49:46)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with Xdebug v2.0.5, Copyright (c) 2002-2008, by Derick Rethans
--------------------------------------------------------------------------------
PHP Fatal error: Maximum function nesting level of '100' reached, aborting! in /var/www/libs2/zf2/library/Zend/Soap/Client/Common.php on line 74
PHP Stack trace:
<!--[if lt IE 7]> <html class="no-js lt-ie10 lt-ie9 lt-ie8 lt-ie7" lang="en"> <![endif]-->
<!--[if IE 7]> <html class="no-js lt-ie10 lt-ie9 lt-ie8" lang="en"> <![endif]-->
<!--[if IE 8]> <html class="no-js lt-ie10 lt-ie9" lang="en"> <![endif]-->
<!--[if IE 9]> <html class="no-js lt-ie10" lang="en"> <![endif]-->
<!--[if gt IE 9]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
@jonathanmaron
jonathanmaron / gist:2792133
Created May 26, 2012 04:07
Custom \Zend\Mvc\Controller\ActionController that passes commonly used variables to the View
<?php
namespace MyNamespace\Mvc\Controller;
use Zend\Mvc\MvcEvent,
Zend\View\Model\ViewModel,
Zend\Date\Date,
MyNamespace\Exception\InvalidArgumentException;
class ActionController extends \Zend\Mvc\Controller\ActionController
<?php
namespace My\View\Helper;
use Zend\View\Helper\AbstractHelper;
class Uri extends AbstractHelper
{
protected $request;
// vendor/MyModule/config/module.config.php
return array(
'view_manager' => array(
'helper_map' => array(
'debugFooter' => 'My\View\Helper\DebugFooter',
'uri' => 'My\View\Helper\Uri',
),
),
// [..]
// this works
'service_manager' => array(
'factories' => array(
'navigation' => function() {
$navigation = new \Application\Navigation\Navigation(
include __DIR__ . '/../navigation/navigation.php');
return $navigation;
}
),
[root@git src]# git clone https://git.gitorious.org/gitorious/ce-installer.git && cd ce-installer
Initialized empty Git repository in /usr/src/ce-installer/.git/
remote: Counting objects: 995, done
remote: Finding sources: 100% (995/995)
remote: Compressing objects: 100% (827/827)
remote: Compressing objects: 100% (827/827)
Receiving objects: 100% (995/995), 149.98 KiB, done.
Resolving deltas: 100% (620/620), done.
[root@git ce-installer]# ./install