Skip to content

Instantly share code, notes, and snippets.

Model/Sponsor.php
class Sponsor extends AppModel {
public $name = 'Sponsor';
public $useTable = 'Sponsors';
public $displayField = 'Sponsor';
public $primaryKey = 'SponsorID';
public $hasMany = array(
'SponsorDivision' => array(
'className' => 'SponsorDivision',
'foreignKey' => 'SponsorID',
@trigeek38
trigeek38 / caesar.erl
Last active December 14, 2015 06:29
Here it is in Erlang :)
-module(caesar).
-export[cipher/2].
cipher(L, Shift) when is_list(L), is_integer(Shift), Shift =< 25, Shift >= -25 ->
%% Anonymous function with guards.
%% Strings are lists of numbers in Erlang [97,98,99] = [$a,$b,$c] = "abc"
%% We evaluat X and add it's shifted value to the head of the accumulator list Acc.
@trigeek38
trigeek38 / Webmachine
Created June 14, 2012 18:29
Webmachine Demo
INTRO and INSTALLATION
git clone git://github.com/basho/webmachine.git
cd webmachine
make
./scripts/new_webmachine.sh gwebdev ../