Skip to content

Instantly share code, notes, and snippets.

View vickyRuiz's full-sized avatar

Vicky Ruiz vickyRuiz

View GitHub Profile
@vickyRuiz
vickyRuiz / reset.min.css
Created May 14, 2014 16:40
CSS: Eric Meyer's Reset (minified)
a,abbr,acronym,address,applet,article,aside,audio,b,big,blockquote,body,canvas,caption,center,cite,code,dd,del,details,dfn,div,dl,dt,em,embed,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,header,hgroup,html,i,iframe,img,ins,kbd,label,legend,li,mark,menu,nav,object,ol,output,p,pre,q,ruby,s,samp,section,small,span,strike,strong,sub,summary,sup,table,tbody,td,tfoot,th,thead,time,tr,tt,u,ul,var,video{margin:0;padding:0;border:0;font-size:100%;vertical-align:baseline}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block}body{line-height:1}ol,ul{list-style:none}blockquote,q{quotes:none}blockquote:after,blockquote:before,q:after,q:before{content:'';content:none}table{border-collapse:collapse;border-spacing:0}a{color:inherit;text-decoration:none}a:active{outline:0}
@vickyRuiz
vickyRuiz / reset.css
Created May 14, 2014 16:39
CSS: Eric Meyer's Reset (one-line)
/* RESET -- http://meyerweb.com/eric/tools/css/reset/ */
html, body, div, span, applet, object, iframe,h1, h2, h3, h4, h5, h6, p, blockquote, pre,a, abbr, acronym, address, big, cite, code,del, dfn, em, img, ins, kbd, q, s, samp,small, strike, strong, sub, sup, tt, var,b, u, i, center,dl, dt, dd, ol, ul, li,fieldset, form, label, legend,table, caption, tbody, tfoot, thead, tr, th, td,article, aside, canvas, details, embed, figure, figcaption, footer, header, hgroup, menu, nav, output, ruby, section, summary,time, mark, audio, video {margin: 0; padding: 0;border: 0; font-size: 100%;vertical-align: baseline;}
/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {display: block;}
body {line-height: 1;}
ol, ul {list-style: none;}
blockquote, q {quotes: none;}
blockquote:before, blockquote:after,q:before, q:after {content: '';content: none;}
table {border-collapse: collapse;border-spacing: 0;}
a {color: inherit; text-decoration:n
@vickyRuiz
vickyRuiz / Bootstrap - additional classes
Created May 14, 2014 15:19
CSS: Bootstrap - additional classes
/* GENERIC CLASSES */
@media (max-width: 480px) {
.mini-hide {display: none;}
.mini-show {display: block !important;}
a .mini-show {display: inline !important;}
.lg-less-hide, .md-less-hide, .sm-less-hide, .xs-less-hide {display: none;}
}
@media (max-width: 767px) {
.xs-show {display: block;}
.xs-hide {display: none;}
@vickyRuiz
vickyRuiz / PHP: Character normalization
Created May 14, 2014 15:16
PHP: Character normalization
$normalizeChars = array(
'Á'=>'A', 'À'=>'A', 'Â'=>'A', 'Ã'=>'A', 'Å'=>'A', 'Ä'=>'A', 'Æ'=>'AE', 'Ç'=>'C',
'É'=>'E', 'È'=>'E', 'Ê'=>'E', 'Ë'=>'E', 'Í'=>'I', 'Ì'=>'I', 'Î'=>'I', 'Ï'=>'I', 'Ð'=>'Eth',
'Ñ'=>'N', 'Ó'=>'O', 'Ò'=>'O', 'Ô'=>'O', 'Õ'=>'O', 'Ö'=>'O', 'Ø'=>'O',
'Ú'=>'U', 'Ù'=>'U', 'Û'=>'U', 'Ü'=>'U', 'Ý'=>'Y',
'á'=>'a', 'à'=>'a', 'â'=>'a', 'ã'=>'a', 'å'=>'a', 'ä'=>'a', 'æ'=>'ae', 'ç'=>'c',
'é'=>'e', 'è'=>'e', 'ê'=>'e', 'ë'=>'e', 'í'=>'i', 'ì'=>'i', 'î'=>'i', 'ï'=>'i', 'ð'=>'eth',
'ñ'=>'n', 'ó'=>'o', 'ò'=>'o', 'ô'=>'o', 'õ'=>'o', 'ö'=>'o', 'ø'=>'o',
'ú'=>'u', 'ù'=>'u', 'û'=>'u', 'ü'=>'u', 'ý'=>'y',
var StrippedString = OriginalString.replace(/(<([^>]+)>)/ig,"");
//From http://css-tricks.com/snippets/javascript/strip-html-tags-in-javascript/