Skip to content

Instantly share code, notes, and snippets.

View ecoleman's full-sized avatar

Eric Coleman ecoleman

View GitHub Profile
// on the feature branches page(s), chrome & safari
Uncaught TypeError: Cannot read property 'destination' of undefined sync.js:14
(anonymous function) sync.js:14
(anonymous function) branches.js:160
(anonymous function) require.js:217
k.each.k.forEach underscore.js:83
i require.js:216
y.execCb require.js:1636
b.check require.js:872
@ecoleman
ecoleman / gist:6168121
Last active December 20, 2015 17:19 — forked from anonymous/gist:6168097
window.accountSigner = function() {
$('.addSigner .addSignerBtn').each(function() {
var next_btn = $('#nextBtn');
$(this).click(function() {
var parent = $(this).parents('.addItem');
parent.addClass('close').hide();
parent.next('article').show();
jQuery.fn.vectorMap("addMap", "us_en", {
insets: [ {
width: 200,
top: 370,
height: 108.57365609908238,
bbox: [ {
y: -9698709.839090653,
x: -19739751.618684802
}, {
y: -6225686.536626536,
jQuery(function($) {
// you can now use $ as query
}(jQuery));
<?php
namespace My\UserBundle\Form;
use My\ContactBundle\Form\BasicPersonType;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
class UserType extends AbstractType
{
Call Stack
# Time Memory Function Location
1 0.0002 247888 {main}( ) ../app_dev.php:0
2 0.0258 3356480 Symfony\Component\HttpKernel\Kernel->handle( ) ../app_dev.php:29
3 0.0910 9178872 Symfony\Bundle\FrameworkBundle\HttpKernel->handle( ) ../bootstrap.php.cache:575
4 0.0910 9180624 Symfony\Component\HttpKernel\HttpKernel->handle( ) ../classes.php:5699
5 0.0910 9180688 Symfony\Component\HttpKernel\HttpKernel->handleRaw( ) ../classes.php:4829
6 0.4017 21309184 call_user_func_array ( ) ../classes.php:4865
7 0.4017 21309520 Blank\ContactBundle\Controller\Backend\NewPersonController->getPersonAction( ) ../classes.php:4865
8 0.4141 21583752 JMS\SerializerBundle\Serializer\Serializer->serialize( ) ../NewPersonController.php:35
<?php
namespace Blank\FunkyBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* Blank\FunkyBundle\Entity\Product
*
* @ORM\Table()
{
"require": {
"symfony/symfony": "dev-master"
, "symfony/swiftmailer-bundle": "dev-master"
, "symfony/monolog-bundle": "dev-master"
, "doctrine/common": "2.2.*"
, "doctrine/dbal": "2.2.*"
, "doctrine/orm": "2.2.*"
@ecoleman
ecoleman / gist:2646936
Created May 9, 2012 17:25
Sort JS Array based on another arrays positions
var positions = ['id1', 'id3', 'id2'];
var data = [{'id' : 'id1'}, {'id': 'id2'}, {'id': 'id3'}];
var sorted = data.sort(function(a, b) {
var a_pos = positions.indexOf(a.id);
var b_pos = positions.indexOf(b.id);
if (a_pos === b_pos)
return 0;
# Associate an alias mapping for the 'fake' fcgi call.
Alias /php5.fcgi /var/www/php5.fcgi
# Assign the 'fake' fcgi to call to an 'external' FastCGI Server
FastCGIExternalServer /var/www/php5.fcgi -flush -host 127.0.0.1:9000
# Create the handler mappings to associate PHP files with a call to '/php5.fcgi'
AddType application/x-httpd-fastphp5 .php
Action application/x-httpd-fastphp5 /php5.fcgi