This file contains hidden or 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 | |
$current_date = date('Y-m-d'); | |
$split_date_now = explode('-', $current_date); | |
$current_timestamp = mktime(0, 0, 0, $split_date_now[1], $split_date_now[2], | |
$split_date_now[0]); |
This file contains hidden or 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
$ tower new myProject | |
create : myProject/.gitignore | |
create : myProject/.npmignore | |
create : myProject/.slugignore | |
create : myProject/Cakefile | |
create : myProject/app/client/config/application.coffee | |
create : myProject/app/client/helpers | |
create : myProject/app/client/stylesheets/application.styl | |
create : myProject/app/client/controllers/applicationController.coffee | |
create : myProject/app/controllers/applicationController.coffee |
This file contains hidden or 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
$ npm install | |
npm http GET https://registry.npmjs.org/design.io | |
npm http 200 https://registry.npmjs.org/design.io | |
npm http GET https://registry.npmjs.org/design.io/-/design.io-0.3.1.tgz | |
npm http GET https://registry.npmjs.org/commander | |
npm http GET https://registry.npmjs.org/socket.io | |
npm http GET https://registry.npmjs.org/seq | |
npm http GET https://registry.npmjs.org/findit | |
npm http GET https://registry.npmjs.org/node-uuid | |
npm http GET https://registry.npmjs.org/underscore.logger |
This file contains hidden or 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
Backbone.sync = (method, model, options = null)-> | |
socket = window.NAMESPACE.socket | |
@signature = (model)-> | |
sig = {} | |
sig.endPoint = model.url + (('/' + model.id) if model.id else '') | |
sig.ctx = model.ctx if model.ctx | |
sig | |
@event = (operation, sig)-> | |
if sig.ctx |
This file contains hidden or 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 | |
$endpoint = new stdClass; | |
$endpoint->disabled = FALSE; | |
$endpoint->api_version = 3; | |
$endpoint->name = 'api'; | |
$endpoint->server = 'rest_server'; | |
$endpoint->path = 'api'; | |
$endpoint->authentication = array( | |
'services' => 'services', | |
); |
This file contains hidden or 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
couleurs = [ | |
'ff0000' | |
'00ff00' | |
'0000ff' | |
] | |
m = Math | |
couleur_de_fond = couleurs[0] | |
cur = m.floor m.round m.random() * (couleurs.length - 1) |
This file contains hidden or 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
chunkize = (string, n = 2)-> | |
string.match RegExp '.{1,'+n+'}','g' |
This file contains hidden or 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 | |
$shop = array( | |
array( | |
'Title' => 'rose', | |
'Price' => 1.25 , | |
'Number' => 15 | |
), | |
array( | |
'Title' => 'daisy', |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title></title> | |
<script> | |
function AudioDataDestination(sR) { | |
var aO = new Audio(), cWpos = 0, pBs = sR / 2, ta = null, taPos; | |
aO.mozSetup(1, sR); | |
setInterval(function() { | |
var w; |
This file contains hidden or 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 | |
$folder = file_directory_path() . '/' . $cache_folder . '/' . $resource_name; | |
$dh = @opendir($folder); | |
$folder .= '/'; | |
$suppressed_file_nb = 0; | |
$files_suppressed_error_nb = 0; | |
$suppressed_file_errors = array(); | |
if ($dh) { | |
while (($file = readdir($dh)) !== false) { | |
if (filetype($folder . $file) !== 'dir' && $file != '.' && $file != '..' && strlen(trim($file)) > 0) { |