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
''' | |
Taken from: | |
http://stackoverflow.com/users/1074592/fakerainbrigand | |
http://stackoverflow.com/questions/15401815/python-simplehttpserver | |
''' | |
import SimpleHTTPServer, SocketServer | |
import urlparse, os | |
PORT = 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
Instale no Ubuntu usando a build 3083 para que a licenca funcione com o comando abaixo para 64 bits: | |
wget http://c758482.r82.cf2.rackcdn.com/sublime-text_build-3083_amd64.deb | |
sudo dpkg -i sublime-text_build-3083_amd64.deb | |
Ou | |
cd /opt | |
wget wget http://c758482.r82.cf2.rackcdn.com/sublime_text_3_build_3083_x64.tar.bz2 | |
tar -jxvf sublime_text_3_build_3083_x64.tar.bz2 |
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
alert("Hello Casta"); |
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
#!/usr/bin/env php | |
<?php | |
error_reporting(-1); | |
ini_set('displayErrors', 1); | |
echo PHP_EOL . PHP_EOL ."====================START========================="; | |
echo PHP_EOL . "RUN ON:\t\t\t\t" . date('d M Y G:i', time()) . PHP_EOL; | |
// Check the host |
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 | |
ini_set('display_errors', 1); | |
error_reporting(-1); | |
$lines = explode(PHP_EOL, file_get_contents('source.txt')); | |
$dir = 'vids'; | |
if (!file_exists($dir)) { | |
mkdir($dir); | |
} |
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
-webkit-tap-highlight-color: rgba(0,0,0,0); | |
-webkit-touch-callout: none; | |
-webkit-user-select: none; | |
-moz-user-select: none; | |
-ms-user-select: none; | |
user-select: none; | |
-webkit-text-size-adjust: none; | |
-moz-text-size-adjust: none; | |
-ms-text-size-adjust: none; | |
-o-text-size-adjust: none; |
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
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
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
// Used to Obfuscate a email address on a page. | |
// Try and stop the bot attacks | |
var username = "john.doe"; | |
var hostname = "example.com"; | |
var linktext = username + "@" + hostname ; | |
document.write("<a style='color:white;' href='" + "mail" + "to:" + linktext + "'>" + linktext + "</a>"); |
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
#!/bin/env php | |
<?php | |
$fileName = 'test.js'; | |
$outputFileName = 'test-out.js'; | |
if (file_exists($fileName)) { | |
var_dump("FROM IO"); | |
$test = file_get_contents($fileName); | |
} 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
<?php | |
$amount = (!empty($_GET['amount'])) ? $_GET['amount'] : 50; | |
$amount = $amount * 100; | |
$amount = (int)$amount; | |
$merchant = (!empty($_GET['merchant'])) ? $_GET['merchant'] : 'snapTest'; | |
header("location:https://pos.snapscan.io/qr/{$merchant}?amount={$amount}&id=TestingTheAccount&strict=true"); |