Skip to content

Instantly share code, notes, and snippets.

Working on a transition plan

Matthew Weier O'Phinney weierophinney

Working on a transition plan
Block or report user

Report or block weierophinney

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:277529
<?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
View gist:277532
<?php
/**
* Zend Framework
*
* LICENSE
*
* This source file is subject to the new BSD license that is bundled
* with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://framework.zend.com/license/new-bsd
View gist:1168465
$sxl = new SimpleXMLElement($url, 0, true);
$item = $sxl->item[0];
$link = (string) $item->link;
@weierophinney
weierophinney / gist:1348598
Created Nov 8, 2011
Prototype of module initialization listener system
View gist:1348598
<?php
interface Installable
{
public function install();
}
interface Upgradable
{
public function upgrade();
}
interface ConfigProvider
View gist:1348655
<?php
public function loadModule($moduleName)
{
if (!isset($this->loadedModules[$moduleName])) {
$class = $moduleName . '\Module';
$module = new $class;
$this->runModuleInit($module);
$this->mergeModuleConfig($module);
$this->loadedModules[$moduleName] = $module;
View runtest.sh
#!/bin/bash
# -------------------------------------------------------------
# Run phpUnit tests for a subset of Zend Framework
# -------------------------------------------------------------
# Author: Enrico Zimuel (enrico@zend.com)
# -------------------------------------------------------------
ZFPATH="/home/matthew/git/zf-standard/tests"
PHP="/home/matthew/svn/phpfarm/inst/bin/php-5.2.17"
PHPUNIT="/home/matthew/Downloads/dev/phpunit-3.4/phpunit/phpunit.php"
View zf1_class
Acl/AclTest.php
Amf/AllTests.php
Application/AllTests.php
Auth/AllTests.php
Barcode/AllTests.php
Cache/AllTests.php
Captcha/AllTests.php
CodeGenerator/AllTests.php
Config/AllTests.php
Console/AllTests.php
View gist:1374245
<?php
array(
'default' => array(
'type' => 'Segment',
'options' => array(
'route' => '/[:controller[/:action]]',
'constraints' => array(
'controller' => '[a-zA-Z][a-zA-Z0-9_-]*',
'action' => '[a-zA-Z][a-zA-Z0-9_-]*',
),
@weierophinney
weierophinney / GuestModule.php
Created Dec 5, 2011
Example listener for changing layouts
View GuestModule.php
<?php
namespace Guest;
use Zend\EventManager\StaticEventManager;
class Module
{
public function init()
{
$events = StaticEventManager::getInstance();
View gist:1443923
<?php
if (!($env = getenv('APPLICATION_ENV'))) {
$env = 'local';
}
$glob = glob(__DIR__ . "/config/autoload/config.{global,$env}.php");
You can’t perform that action at this time.