Consider this a work in progress forever more.
- zip
- unzip
- ack
- git
- git-flow
<?php | |
// idea based upon http://www.hashbangcode.com/blog/php-array-countries | |
// copy/paste from http://en.wikipedia.org/wiki/ISO_3166-1#Officially_assigned_code_elements | |
$countriesString = "Afghanistan AF AFG 004 ISO 3166-2:AF | |
Åland Islands AX ALA 248 ISO 3166-2:AX | |
Albania AL ALB 008 ISO 3166-2:AL | |
Algeria DZ DZA 012 ISO 3166-2:DZ | |
American Samoa AS ASM 016 ISO 3166-2:AS | |
Andorra AD AND 020 ISO 3166-2:AD |
<?php | |
$baseDir = "mp3s"; | |
$soundcloudURL = "http://soundcloud.com/ninja-tune/sets/solid-steel-radio-shows/"; | |
$urlBits = str_replace('http://', '', $soundcloudURL); | |
$urlBits = preg_replace('@/$@', '', $urlBits); | |
$urlBits = explode("/", $urlBits); | |
/** | |
* http://soundcloud.com/ninja-tune/sets/solid-steel-radio-shows/ |
<?php | |
namespace My\Bundle\BlockBundle\Block; | |
use Symfony\Component\HttpFoundation\Response; | |
use Sonata\BlockBundle\Model\BlockInterface; | |
use Sonata\BlockBundle\Block\BaseBlockService; | |
use Sonata\AdminBundle\Form\FormMapper; | |
use Sonata\AdminBundle\Validator\ErrorElement; |
<ul> | |
{% for project in pagination %} | |
<li>{{ project.name }} has {{ project.?? }} tasks</li> | |
{% endfor %} | |
</ul> |
<?php | |
namespace Acme\DemoBundle\Repository; | |
use Symfony\Component\DependencyInjection\ContainerInterface; | |
use Symfony\Component\DependencyInjection\ContainerAwareInterface; | |
use Doctrine\ORM\EntityRepository; | |
/** |
<?php | |
$topUp = 100; | |
list($integerPart1, $integerPart2) = convertTo48bit($topUp); | |
$packedInteger = pack("vV", $integerPart1, $integerPart2); | |
echo json_encode($packedInteger) . "\n"; |