Skip to content

Instantly share code, notes, and snippets.

@Nully
Nully / Maintenance.php
Created May 27, 2011 16:09
Zend_Application_Resouce_Maintenance
<?php
/**
* Zend Framework - メンテナンスモードプラグイン
*/
require_once "Zend/Controller/Plugin/Abstract.php";
class Zend_Controller_Plugin_Maintenance
extends Zend_Controller_Plugin_Abstract
{
@Nully
Nully / gist:719692
Created November 29, 2010 07:30
URLValidator
<?php
class Nully_Validate_Uri extends Zend_Validate_Abstract {
const INVALID_URI = "%value% is invalid URI";
/**
* Checking for http including URI pattern.
*
* @uses Zend_Uri
* Zend_Uri::check method is checking URI scheme including pattern.
*/
@Nully
Nully / gist:713140
Created November 24, 2010 04:58
PeaerPackageInstaller
#!/usr/bin/env ruby
`pear remote-list`.each_line do |p|
puts p.split(/\s+/)[0]
`pear install -f #{p.split(/\s+/)[0]}`
end