This is a super-simple cinnamon roll recipe by Amy Hafner that even programmers can follow.
- 1 package/box of yellow cake mix
- 2 packages of yeast
- 5 cups of flour
- 2 1/2 cups of hot water
function snippet($text,$length=100,$tail="...") { | |
$text = strip_tags($text); | |
$text = trim($text); | |
$txtl = strlen($text); | |
if($txtl > $length) { | |
for($i=1;$text[$length-$i]!=" ";$i++) { | |
if($i == $length) { | |
return substr($text,0,$length) . $tail; | |
} | |
} |
<a href="index.php?option=com_user&task=logout&return=aW5kZXgucGhw" title="Sign Out">Sign Out</a> |
for i in $(find /home/*/public_html -maxdepth 0); do u=$(echo $i | awk -F '/' '{print $3}') && chown -R $u:$u $i; done | |
for i in $(grep DocumentRoot /usr/local/apache/conf/httpd.conf | awk '{print $2}' | grep -v /usr/local/apache/htdocs); do chgrp nobody $i; done | |
find /home/*/public_html -type d -exec chmod 755 '{}' ';' | |
find /home/*/public_html -type f -exec chmod 644 '{}' ';' | |
find /home/*/public_html -iwholename '*.cgi' -exec chmod 755 '{}' ';' | |
find /home/*/public_html -iwholename '*.pl' -exec chmod 755 '{}' ';' |
var x; // Screen Width | |
var y; // Screen Height | |
function screenSize(){ | |
var w=window,d=document,e=d.documentElement,g=d.getElementsByTagName('body')[0],x=w.innerWidth||e.clientWidth||g.clientWidth,y=w.innerHeight||e.clientHeight||g.clientHeight; | |
console.log('x: ' + x + 'px | y: ' + y + 'px'); | |
} | |
screenSize(); |
module ApplicationHelper | |
def conditional_html( lang = "en", &block ) | |
haml_concat Haml::Util::html_safe <<-"HTML".gsub( /^\s+/, '' ) | |
<!--[if lt IE 7 ]> <html lang="#{lang}" class="no-js ie6"> <![endif]--> | |
<!--[if IE 7 ]> <html lang="#{lang}" class="no-js ie7"> <![endif]--> | |
<!--[if IE 8 ]> <html lang="#{lang}" class="no-js ie8"> <![endif]--> | |
<!--[if IE 9 ]> <html lang="#{lang}" class="no-js ie9"> <![endif]--> | |
<!--[if (gte IE 9)|!(IE)]><!--> <html lang="#{lang}" class="no-js"> <!--<![endif]--> | |
HTML |
html, body, input, select, textarea {font-size: 13px !important;} | |
#header {background: #2B2B2B !important;} | |
.header-btn.header-notifications, .header-btn.header-boards, | |
.header-btn.header-search, .header-btn.header-login, | |
.header-btn.header-signup { | |
background: #6B6B6B !important; | |
} | |
.header-btn:hover {background: #868686 !important;} |
#!/bin/bash | |
git_host='[email protected]:' | |
git_url='https://github.com/' | |
remote=`git config --get remote.origin.url` | |
host=${remote:0:15} | |
if [ $host = $git_host ] | |
then | |
url=${remote/$git_host/$git_url} |
/* Smartphones (portrait and landscape) ----------- */ | |
@media only screen | |
and (min-device-width : 320px) and (max-device-width : 480px) { | |
/* Styles */ | |
} | |
/* Smartphones (landscape) ----------- */ | |
@media only screen and (min-width : 321px) { | |
/* Styles */ | |
} |
/* Times New Roman-based serif */ | |
font-family: Cambria, "Hoefler Text", Utopia, "Liberation Serif", "Nimbus Roman No9 L Regular", Times, "Times New Roman", serif; | |
/* A modern Georgia-based serif */ | |
font-family: Constantia, "Lucida Bright", Lucidabright, "Lucida Serif", Lucida, "DejaVu Serif," "Bitstream Vera Serif", "Liberation Serif", Georgia, serif; | |
/*A more traditional Garamond-based serif */ | |
font-family: "Palatino Linotype", Palatino, Palladio, "URW Palladio L", "Book Antiqua", Baskerville, "Bookman Old Style", "Bitstream Charter", "Nimbus Roman No9 L", Garamond, "Apple Garamond", "ITC Garamond Narrow", "New Century Schoolbook", "Century Schoolbook", "Century Schoolbook L", Georgia, serif; | |
/*The Helvetica/Arial-based sans serif */ |