This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function consumer() { | |
return new oauth.OAuth( | |
"https://twitter.com/oauth/request_token", | |
"https://twitter.com/oauth/access_token", | |
keys.twitterConsumerKey, | |
keys.twitterConsumerSecret, | |
"1.0A", | |
"http://localhost:3000/sessions/callback", | |
"HMAC-SHA1" | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*! | |
* MailWrapper - An extremely simple nodemailer wrapper library that makes it easy to send emails using Express and Jade templates. Originally | |
* developed to practice and learn how to write modules for node. | |
* | |
* Copyright(c) 2011 Tom Shaw <tom@tomshaw.info> | |
* MIT Licensed | |
*/ | |
var mailer = require('./lib/mailer'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; A fun route access /install by /setup | |
resources.router.routes.install.type = "Zend_Controller_Router_Route_Static" | |
resources.router.routes.install.route = "setup" | |
resources.router.routes.install.defaults.module = "install" | |
resources.router.routes.install.defaults.controller = "index" | |
resources.router.routes.install.defaults.action = "index" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$loader = require __DIR__.'/vendor/autoload.php'; | |
$loader->add('React', __DIR__); | |
$loop = React\EventLoop\Factory::create(); | |
$files = array( | |
'node-v0.6.18.tar.gz' => 'http://nodejs.org/dist/v0.6.18/node-v0.6.18.tar.gz', | |
'php-5.4.3.tar.gz' => 'http://it.php.net/get/php-5.4.3.tar.gz/from/this/mirror', | |
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.CustomerListView = Backbone.View.extend({ | |
template: _.template($('#CustomerListView').html()), | |
page: 1, | |
sort: 'asc', | |
search: { | |
name: "", | |
email: "", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var callServer = function(args, callback) { | |
var url = "http://www.urbandictionary.com/iphone/search/define"; | |
$.ajax({ | |
url: url, | |
data: args, | |
dataType: "jsonp", | |
type: "GET", | |
success: function(result) { | |
callback(result); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define('AppLoad', ['jquery', 'underscore', 'backbone', 'AppConfig', 'ProjectCollection', 'PhotographyCollection'], function ($, _, Backbone, AppConfig, ProjectCollection, PhotographyCollection) { | |
var AppLoad = _.extend({}, Backbone.Events); | |
AppLoad.GDRIVE_LOADED = 'GDRIVE_LOADED'; | |
AppLoad.projectCollection = null; | |
AppLoad.photographyCollection = null; | |
AppLoad.totalLoaded = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace HTMLPurifier\Controller\Plugin; | |
use Zend\Mvc\Controller\Plugin\AbstractPlugin; | |
class Purifier extends AbstractPlugin | |
{ | |
public function __invoke($data) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Application\Controller\Plugin; | |
use Zend\Mvc\Controller\Plugin\AbstractPlugin; | |
use Zend\Debug\Debug; | |
class Dump extends AbstractPlugin | |
{ | |
public function __invoke($var, $label = null, $echo = true) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$select->where | |
->literal('LOWER(campaign.title) LIKE "%'.strtolower($data['search']).'%"') | |
->or | |
->literal('LOWER(campaign.description) LIKE "%'.strtolower($data['search']).'%"'); |
OlderNewer