Skip to content

Instantly share code, notes, and snippets.

View gist:2282102
No entry for terminal type "unknown";
using dumb terminal settings.
Populating jobs from BR
Populating jobs from CA
Populating jobs from US
Populating jobs from NL
Populating jobs from NO
Populating jobs from ZA
Populating jobs from ES
Populating jobs from SE
View gist:2282089
function getArgs(){
global $argv;
$args = array('task_id' => null, 'dir' => null, 'payload' => array());
foreach($argv as $k => $v){
if (empty($argv[$k+1])) continue;
if ($v == '-id') $args['task_id'] = $argv[$k+1];
if ($v == '-d') $args['dir'] = $argv[$k+1];
if ($v == '-payload' && file_exists($argv[$k+1])){
View gist:1451435
<%@ Page Title="" Language="C#" MasterPageFile="~/Content.master" AutoEventWireup="true" CodeFile="search.aspx.cs" Inherits="footer_search" %>
<asp:Content ID="Content8" ContentPlaceHolderID="searchScript" Runat="Server">
<script src="" type="text/javascript"></script>
<script type="text/javascript">
$(function () {
View gist:1451400
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="home.aspx.cs" Inherits="home" Title="-removed- 15th Anniversary Website -Home Page" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "">
<html xmlns="" xml:lang="en">
<head id="Head1" runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<script type="text/javascript" src="/library/js/jquery.js"></script>
<script type="text/javascript" src="/library/js/hoverIntent.js"></script>
<script type="text/javascript" src="/library/js/superfish.js"></script>
codecowboy / gist:1324206
Created Oct 29, 2011
View gist:1324206
public function indexAction()
$user = $user = $this->get('security.context')->getToken()->getUser();
$challenge = $this->getDoctrine()
if(!$challenge) {
throw $this->createNotFoundException('No challenge found');
codecowboy / gist:1261012
Created Oct 4, 2011
Change password form
View gist:1261012
<div id="change_password_wrapper">
<h2>Change your password</h2>
<form action="{{ path('fos_user_change_password') }}" {{ form_enctype(form) }} method="POST" class="fos_user_change_password">
{%if form_errors(form)%}
<div class="ui-state-error ui-corner-all">
<span class="ui-icon ui-icon-alert" style="float: left; margin-right: .3em;"></span>
{{ form_errors(form) }}
codecowboy / gist:1260992
Created Oct 4, 2011
Profile Form Handler
View gist:1260992
* This file is part of the FOSUserBundle package.
* (c) FriendsOfSymfony <>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
View gist:1258990
namespace Gymloop\ChallengeBundle\Controller;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Gymloop\CoreBundle\Entity\Challenge;
use Gymloop\CoreBundle\Entity\ChallengeCoordinates;
class DefaultController extends Controller