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> | |
<head> | |
<meta charset="utf-8"> | |
<title>Responsive Design Testing</title> | |
<style> | |
body { margin: 20px; font-family: sans-serif; overflow-x: scroll; } | |
.wrapper { width: 6000px; } | |
.frame { float: left; } | |
h2 { margin: 0 0 5px 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
<!-- attempt to load AngularJS from CDN --> | |
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.2.19/angular.min.js"></script> | |
<!-- if AngularJS fails to load fallback a local version --> | |
<script>window.angular || document.write('<script src="/assets/js/vendor/angularjs/1.2.19/angular.min.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
/* Flatten das boostrap */ | |
.well, .navbar-inner, .popover, .btn, .tooltip, input, select, textarea, pre, .progress, .modal, .add-on, .alert, .table-bordered, .nav>.active>a, .dropdown-menu, .tooltip-inner, .badge, .label, .img-polaroid { | |
-moz-box-shadow: none !important; | |
-webkit-box-shadow: none !important; | |
box-shadow: none !important; | |
-webkit-border-radius: 0px !important; | |
-moz-border-radius: 0px !important; | |
border-radius: 0px !important; | |
border-collapse: collapse !important; | |
background-image: none !important; |
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
/** | |
* Twitter Boostrap Flat | |
* Based on https://gist.github.com/nodesocket/5843712 | |
*/ | |
.well, .navbar-inner, .popover, .btn, .tooltip, input, select, textarea, pre, .progress, .modal, .add-on, .alert, .table-bordered, .nav>.active>a, .dropdown-menu, .tooltip-inner, .badge, .label, .img-polaroid { | |
-moz-box-shadow: none !important; | |
-webkit-box-shadow: none !important; | |
box-shadow: none !important; | |
border-collapse: collapse !important; | |
background-image: none !important; |
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 | |
# This script check for errors before commmit | |
# | |
# Add execute permissions first: chmod +x pre-commit | |
# | |
# Search for debug information inside .php files | |
# var_dump() , print_r(), die(), dd() y shortag | |
# If found any, stops the commit | |
# Put this file inside .git/hooks in your clone copy | |
# https://stackoverflow.com/questions/6879501/filter-git-diff-by-type-of-change |
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 App\Http\Controllers; | |
use Illuminate\Http\Request; | |
class PageController extends \App\Http\Controllers\Controller | |
{ | |
public function show() | |
{ | |
$slug = request()->segment(1); |
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 formatCrediCard(cardtype, number) | |
{ | |
let format; | |
if(cardtype == 'amex') | |
{ | |
//XXXX XXXXXX XXXXX | |
format = number.substr(0,4)+" "+number.substr(4,6)+" "+number.substr(10,5); | |
} else { | |
//XXXX XXXX XXXX XXXX | |
format = number.substr(0,4)+" "+number.substr(4,4)+" "+number.substr(8,4)+" "+number.substr(12,4); |
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 | |
# One Click LAMP Server Installer (Ubuntu/Debian) - Roskus | |
# @author Gustavo Novaro | |
# @version 3.3.1 | |
# @url https://gist.github.com/gnovaro/5295150774be1794028c15c83313c16e | |
# Run: sudo ./lamp_setup.sh | |
############################################### | |
#Servidor Web http | |
apt-get install -y nginx |
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 | |
/** | |
* Error Log Tail | |
* @author Gustavo Novaro | |
* @version 1.0.3 | |
* Set in php.ini error_log= | |
*/ | |
// Linux Path | |
$log_path = '/var/log/php_error.log'; | |
// Windows path |
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 | |
// routes/console.php | |
// quickly create an user via the command line | |
Artisan::command('user:create', function () { | |
$name = $this->ask('Name?'); | |
$email = $this->ask('Email?'); | |
$pwd = $this->ask('Password?'); | |
// $pwd = $this->secret('Password?'); // or use secret() to hide the password being inputted | |
\DB::table('users')->insert([ |
OlderNewer