Skip to content

Instantly share code, notes, and snippets.

View peschee's full-sized avatar
Grabbing another coffee…

Peter Siska peschee

Grabbing another coffee…
View GitHub Profile
<?php
namespace Acme\HelloBundle\Menu;
use Knp\Menu\FactoryInterface;
use Symfony\Component\DependencyInjection\ContainerAware;
class MenuBuilder extends ContainerAware
{
public function mainMenu(FactoryInterface $factory, array $options)
#!/bin/bash
# php switch for homebrew
# $ brew tap josegonzalez/php && brew install php53 --with-mysql && brew install php54 --with-mysql
# Might as well ask for password up-front, right?
sudo -v
VERSION_FILE="$( cd -P "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/php-switch.version"

Awesome PHP Libraries

A list of amazingly awesome PHP libraries that you should consider using (and some other shiny extras).

<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
// Multiple if statements, or a switch statement,
// can handle as many environments as you need
if ($_SERVER['HTTP_HOST'] == "local-site.dev") {
$active_group = 'expressionengine';
} else {
$active_group = 'enginehosting';
}
git init
git submodule add git://github.com/kohana/core.git system
git submodule add git://github.com/kohana/database.git modules/database
git submodule add http://github.com/kohana/userguide.git modules/userguide
git submodule add http://github.com/kohana/image.git modules/image
git submodule add http://github.com/kohana/codebench.git modules/codebench
git submodule add http://github.com/kohana/auth.git modules/auth
git submodule add http://github.com/kohana/pagination.git modules/pagination
git submodule add http://github.com/kohana/orm.git modules/orm