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
# compress text, html, javascript, css, xml: | |
AddOutputFilterByType DEFLATE text/plain | |
AddOutputFilterByType DEFLATE text/html | |
AddOutputFilterByType DEFLATE text/xml | |
AddOutputFilterByType DEFLATE text/css | |
AddOutputFilterByType DEFLATE application/xml | |
AddOutputFilterByType DEFLATE application/xhtml+xml | |
AddOutputFilterByType DEFLATE application/rss+xml | |
AddOutputFilterByType DEFLATE application/javascript | |
AddOutputFilterByType DEFLATE application/x-javascript |
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
#in cygwin: (your adb path may vary) | |
cd c:/Program\ Files\ \(x86\)/adt-bundle-windows-x86_64-20140702/sdk/platform-tools | |
adb devices |
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
//based on https://gist.github.com/pburtchaell/e702f441ba9b3f76f587 | |
//with added support for iphone 3 and 4 and orinetation support for iphone 5. | |
//this is for all devices which can run iOS7 in all orientations. | |
//not a mixin to avoid to much duplicate code when using on multiple selectors. | |
.selector { | |
$height: 70; //set your height in vh | |
$heightPercent: $height/100; | |
height: #{$height}vh; | |
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
$bpxs: 480px; | |
$bps: 640px; | |
$bpm: 768px; | |
$bpl: 990px; | |
$bpxl: 1200px; |
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
#change $1.php to whatever extension you wish to remove | |
RewriteEngine On | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteRule ^([^\.]+)$ $1.php [NC,L] |
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
<!-- demo@ http://jopf.re/squarespirals --> | |
<textarea cols="30" rows="3">9 | |
6 8 </textarea> | |
<button>calculate</button> | |
<p></p> | |
<script type="text/javascript"> | |
var button = document.getElementsByTagName('button')[0]; | |
var output = document.getElementsByTagName('p')[0]; | |
var input, spiralSize, queryPointNumber, queryCoordiante, center, square, pointNumber, quarterSquare, quarterSquares, dx, dy, direction, squareHTML, queryHTML; |
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
#server side force download of files ending with 'download.pdf' | |
<FilesMatch "download\.pdf$"> | |
ForceType application/octet-stream | |
Header set Content-Disposition attachment | |
</FilesMatch> |
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
AddType image/svg+xml svg svgz | |
AddEncoding gzip svgz |
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 add_timestamp_to_childtheme_stylesheet() { | |
wp_dequeue_style( 'style' ); | |
wp_deregister_style( 'style' ); | |
wp_enqueue_style('style', get_stylesheet_uri().'?'.filemtime(get_stylesheet_directory().'/style.css'), array(), null); | |
} | |
add_action( 'wp_print_styles', 'add_timestamp_to_childtheme_stylesheet' ); |
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
Set A record for blank (root) to ip | |
Set A record for www to ip - in tso this is done by selecting the www domain from the drop down | |
Set MX record to mail.domain-name.com | |
Set TTL to 300 for all (may only apply to TSO domain providings, ask other providers for their nameservers TTL) |
OlderNewer