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
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8" /> | |
<title>jQuery UI Tabs - Default functionality</title> | |
<link rel="stylesheet" href="http://code.jquery.com/ui/1.10.3/themes/smoothness/jquery-ui.css" /> | |
<script src="http://code.jquery.com/jquery-1.7.2.js"></script> | |
<script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script> | |
<script> |
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
ffmpeg -i "File.mkv" -f avi -c:v mpeg4 -b:v 4000k -c:a libmp3lame -b:a 320k "File.avi" |
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 | |
// Based upon http://goo.gl/406o | |
class CliColor | |
{ | |
private $colors = array(); | |
private $bgcolors = array(); | |
public function __construct() | |
{ | |
// Set up shell colors |
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
# User specific aliases and functions | |
function _git_prompt() { | |
local git_status="`git status -unormal 2>&1`" | |
if ! [[ "$git_status" =~ Not\ a\ git\ repo ]]; then | |
if [[ "$git_status" =~ nothing\ to\ commit ]]; then | |
local ansi=32 | |
elif [[ "$git_status" =~ nothing\ added\ to\ commit\ but\ untracked\ files\ present ]]; then | |
local ansi=34 | |
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
#!/bin/sh | |
# Check if an IP address is listed on one of the following blacklists | |
# The format is chosen to make it easy to add or delete | |
# The shell will strip multiple whitespace | |
BLISTS=" | |
b.barracudacentral.org | |
bb.barracudacentral.org | |
bl.deadbeef.com | |
bl.mailspike.net |
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 | |
/** | |
* Generador de palabras o nombres aleatorios | |
* | |
* @param integer $min longitud mínima de la palabra | |
* @param integer $max longitud máxima de la palabra | |
* @return string palabra generada | |
*/ | |
function nombreAleatorio($min = 3, $max = 10) { |
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('zlib.output_compression', 0); | |
@ini_set('output_buffering', 0); | |
@ob_end_clean(); | |
ob_implicit_flush(true); | |
for($i=0; $i<10; $i++){ | |
echo $i; |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Upload file</title> | |
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"> | |
</head> | |
<body> | |
<div class="container jumbotron"> | |
<h1>Upload file</h1> |
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 | |
/** | |
* | |
* Extract all email address from any text content removing duplicated | |
* Return string formated as: TEXT, SQL or CSV | |
* @author Alexander Garzon | |
* | |
*/ | |
class emailXtractor { |
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/bash | |
#Require root SSH access by authentication file | |
TEMPFILE=`mktemp -p /tmp` | |
HOSTNAME=`hostname` | |
MASTERS=`hostname -i` | |
REMOTE_URI="[email protected]" | |
SLAVE_PATH="/var/named/chroot/etc/" | |
for domain in `egrep '^zone' /etc/named.conf | egrep -iv "arpa|\"\." | egrep -iv "domain.com" | awk -F\" '{print $2}'` | |
do printf "zone \"${domain}\" {\n\t type slave;\n\t file \"/var/named/slaves/${domain}.db\";\n\t masters { ${MASTERS}; };\n};\n\n" |