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
<div style="font-family: sans-serif;"> | |
<? var data = valid(); ?> | |
<form id="form" name="form"> | |
<? if(Object.prototype.toString.call(data) === '[object Array]') { ?> | |
<? for (var i = 0; i < data.length; i++) { ?> | |
<? for (var j = 0; j < data[i].length; j++) { ?> | |
<input type="checkbox" id="ch<?= '' + i + j ?>" name="ch<?= '' + i + j ?>" value="<?= data[i][j] ?>"><?= data[i][j] ?><br> | |
<? } ?> | |
<? } ?> | |
<? } else { ?> |
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
// More details + demo : | |
// ***************************************************************** | |
// ===> http://cristianciofu.github.io/cheat-game-leclerc/ | |
// ***************************************************************** | |
// #1 : JS version : | |
var colors=["#0F5858","#F0A458","#50F1FF","#FF0000","#0062F6","#AF0F40","#FF00FF","#0FF4C6","#00CC00"],matches=[];$.each($("#game>div.card"),function(a,b){$.inArray($("#"+b.id).data("id"),matches)<0&&matches.push($("#"+b.id).data("id")),$("#"+b.id).css("border","8px solid "+colors[$.inArray($("#"+b.id).data("id"),matches)])}),$("#game>div.card").click(function(){$(this).css("border","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
var express = require("express"); | |
var app = express(); | |
app | |
.use(express.static('./')) | |
.get('*', function(req, res) { | |
res.sendFile(__dirname + '/index.html'); | |
}) | |
.listen(3000); |
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
rsync --progress /copy/from /copy/to |
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
[xdebug] | |
zend_extension="/Applications/MAMP/bin/php/php5.3.6/lib/php/extensions/no-debug-non-zts-20090626/xdebug.so" | |
xdebug.profiler_enable = 1 | |
xdebug.profiler_output_dir = "/tmp" |
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
Add this in .screenrc : | |
caption always "%{= kw}%-w%{= BW}%n %t%{-}%+w %-= @%H - %LD %d %LM - %c" |
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
@media print | |
{ | |
div.className { | |
page-break-inside: avoid; | |
} | |
} |
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 | |
function import_csv_to_sqlite(&$pdo, $csv_path, $options = array()) | |
{ | |
extract($options); | |
if (($csv_handle = fopen($csv_path, "r")) === FALSE) | |
throw new Exception('Cannot open CSV file'); | |
if(!$delimiter) | |
$delimiter = ','; |
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
<!-- | |
Generate getters and setters for your php sources | |
usage : gs <tab> | |
(c) http://akrabat.com/software/improved-sublime-text-2-php-getter-and-setter-generation/ | |
--> |
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
[ | |
{ "keys": ["ctrl+d"], "command": "run_macro_file", "args": {"file": "Packages/Default/Delete Line.sublime-macro"} }, | |
{ "keys": ["ctrl+shift+up"], "command": "duplicate_line" }, | |
{ "keys": ["ctrl+shift+down"], "command": "duplicate_line" }, | |
{ "keys": ["alt+up"], "command": "swap_line_up" }, | |
{ "keys": ["alt+down"], "command": "swap_line_down" }, | |
{ "keys": ["ctrl+shift+d"], "command": "find_under_expand" }, |
NewerOlder