This gist shows how to create a GIF screencast using only free OS X tools: QuickTime, ffmpeg, and gifsicle.
To capture the video (filesize: 19MB), using the free "QuickTime Player" application:
$.fn.serializeToObject = function() { | |
var serial_array = this.serializeArray(); | |
var serial_object = {}; | |
$(serial_array).each(function() { | |
if( !serial_object[this.name] ) | |
{ | |
serial_object[this.name] = this.value; | |
} | |
}); | |
return serial_object; |
QUERY ::= 'SELECT' ('COUNT()' | (FIELD ( ',' FIELD)*)) | |
'FROM' (NAME ('AS' ? NAME)? ('USING' NAME)?) ( ',' NAME ('AS' ? NAME)? ('USING' NAME)?)* | |
('WHERE' CONDITIONEXPR )? | |
('ORDER BY' ORDERBYEXPR)? | |
('LIMIT' POSINTEGER )? | |
FIELD ::= NAME | '(' QUERY ')' | |
CONDITIONEXPR ::= ANDEXPR | OREXPR | NOTEXPR | SIMPLEEXPR | |
ANDEXPR ::= 'AND' SIMPLEEXPR | |
OREXPR ::= 'OR' SIMPLEEXPR | |
NOTEXPR ::= 'NOT' SIMPLEEXPR |
<?php | |
echo 'default locale: ' . \Locale::getDefault(); | |
echo PHP_EOL; | |
echo 'default timezone: ' . \date_default_timezone_get(); | |
echo PHP_EOL; | |
// see http://tools.ietf.org/html/rfc3339#section-5.8 for example datetimes | |
// bug report on missing fractions support: https://bugs.php.net/bug.php?id=51950 | |
// feature request for fractions support in constructor: https://bugs.php.net/bug.php?id=49779 |
### Keybase proof | |
I hereby claim: | |
* I am thinkt4nk on github. | |
* I am ryanbales (https://keybase.io/ryanbales) on keybase. | |
* I have a public key whose fingerprint is C572 6356 A206 F878 70D0 EA4E 4CE1 54BE 0F9B F3ED | |
To claim this, I am signing this object: |
<?php | |
/** | |
* Took the components necessary to render views from CController, adding it to a console command | |
*/ | |
class RenderReadyConsoleCommand extends CConsoleCommand | |
{ | |
protected $_widgetStack; | |
public function run($args) { } | |
public function renderPartial($view,$data=null,$return=true) | |
{ |
/** | |
* EventEmitter with jQuery 1.7's $.Callbacks(). | |
*/ | |
function EventEmitter() { | |
this.topics = {}; | |
} | |
/** | |
* Listen on the given `topic` event with `fn`. |
/* | |
* upload_to_ambition.cs | |
* Simple program demonstrating how to upload data to the Ambition Data API | |
* | |
* This code needs to be linked to the System.Web.Extensions assembly. | |
* | |
* For mono, use 'gmcs ambition_api_c#_example.cs -r:System.Web.Extensions' | |
*/ | |
using System; |
#!/usr/bin/python | |
import os | |
import sys | |
ignore_paths = ['apps/ppc/templates/_scripts.php'] | |
# chdir to project root | |
os.chdir(os.path.join(os.path.abspath(os.path.dirname(__file__)),'..','..')) | |
# for each path, reset and re-checkout before commit | |
for path in ignore_paths: | |
ignore_file = os.path.join(os.getcwd(),path) |
(function($) { | |
var serialize = function(type,form) { | |
var data = {}; | |
var first_run_ignore_types = ['submit','checkbox']; | |
form.find('input, select').each(function() { | |
var input_type = $(this).attr('type'); | |
var input_name = $(this).attr('name'); | |
if (first_run_ignore_types.indexOf(input_type) === -1) { | |
// process and push to data |