A tweet-sized debugger for visualizing your CSS layouts. Outlines every DOM element on your page a random (valid) CSS hex color.
One-line version to paste in your DevTools
Use $$ if your browser aliases it:
~ 108 byte version
| $base-font-size: 16px; | |
| $base-line-height: 1.5; | |
| // this value may vary for each font | |
| // unitless value relative to 1em | |
| $cap-height: 0.68; | |
| @mixin baseline($font-size, $scale: 2) { |
| /******************************************************************************* | |
| 1. DEPENDENCIES | |
| *******************************************************************************/ | |
| var gulp = require('gulp'); // gulp core | |
| sass = require('gulp-sass'), // sass compiler | |
| uglify = require('gulp-uglify'), // uglifies the js | |
| jshint = require('gulp-jshint'), // check if js is ok | |
| rename = require("gulp-rename"); // rename files | |
| concat = require('gulp-concat'), // concatinate js |
| // Stick all your icons in a subfolder in your images folder. Put retina versions in a subfolder of that called "@2x". | |
| $sprites: sprite-map("NAME_OF_SUBFOLDER/*.png"); | |
| $sprites2x: sprite-map("NAME_OF_SUBFOLDER/@2x/*.png"); | |
| // stolen from 37signals | |
| @mixin retina-media() { | |
| @media (min--moz-device-pixel-ratio: 1.3), | |
| (-webkit-min-device-pixel-ratio: 1.3), | |
| (min-device-pixel-ratio: 1.3), | |
| (min-resolution: 1.3dppx) { |
| <?php | |
| /* | |
| * PHP: Recursively Backup Files & Folders to ZIP-File | |
| * MIT-License - 2012-2018 Marvin Menzerath | |
| */ | |
| // Make sure the script can handle large folders/files | |
| ini_set('max_execution_time', 600); | |
| ini_set('memory_limit', '1024M'); |
| //http://iamskwerl.com/tech/2012/11/flash-detection-with-one-line-of-javascript/ | |
| var hasFlash = navigator.mimeTypes && navigator.mimeTypes.length ? Array.prototype.slice.call(navigator.mimeTypes).some(function(a) { return "application/x-shockwave-flash" == a.type; }) : /MSIE/.test(navigator.userAgent) ? eval("try { new ActiveXObject('ShockwaveFlash.ShockwaveFlash') && !0 } catch(e) { !1 };") : !1; |
| # 1. in case you haven't installed the latest SASS | |
| $ sudo gem install sass | |
| # 2. now let's symlink the system Sass into the Livereload bundle | |
| cd /Applications/LiveReload.app/Contents/Resources/SASS.lrplugin/lib | |
| sudo mv sass sass-bundled | |
| sudo ln -s /Library/Ruby/Gems/1.8/gems/sass-3.2.1/ sass | |
| # 3. done. enjoy the lovely new features like @content for awesome @media support :-) |
| <?php | |
| /** | |
| * IssuuClient hooks into Issuu's API | |
| * | |
| * example: | |
| * include 'IssuuClient.php'; | |
| * $issuu = new IssuuClient(pubKey, privKey, apiAdr); | |
| * $issuu->openAction('issuu.document.url_upload'); | |
| * $issuu->slurpUrl = 'pdfurl.pdf'; | |
| * $issuu->executeAction(); |