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
for file in ./*.png; | |
do | |
if grep -q ${file:2} ./fileslist.txt; | |
then | |
echo "skipping $file" | |
else | |
echo "moving $file" | |
mv "$f" ./newdir | |
fi | |
done |
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
/** | |
* os-leaflet ; A [Leafletjs](http://leafletjs.com/) TileLayer to display Ordnance Survey | |
* data in your Leaflet map via the OS OpenSpace web map service. | |
* | |
* https://github.com/rob-murray/os-leaflet | |
*/ | |
(function (root, factory) { | |
// UMD for Node, AMD or browser globals | |
if (typeof define === 'function' && define.amd) { | |
// AMD. Register as an anonymous module. |
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
ffmpeg -i input.mp4 -strict -2 -movflags faststart -vcodec libx264 -crf 24 output.mp4 |
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
RewriteEngine On | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME}.html -f | |
RewriteRule ^(.*)$ $1.html [NC,L] | |
DirectoryIndex index.html index.php |
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
$query="SELECT * FROM word WHERE day = current_date() LIMIT 1"; | |
$result = mysql_query($query); | |
if ($result) { | |
// echo "Query executed"; | |
$row = mysql_fetch_assoc($result); | |
$word = $row['word']; | |
$definition = $row['definition']; | |
$definitionB = $row['definitionB']; | |
} else { | |
echo "Query not executed"; |
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
#http://stackoverflow.com/a/27029144 | |
RewriteEngine On | |
# match any URL with www and rewrite it to https without the www | |
RewriteCond %{HTTP_HOST} ^(www\.)(.*) [NC] | |
RewriteRule (.*) https://%2%{REQUEST_URI} [L,R=301] | |
# match urls that are non https (without the www) | |
RewriteCond %{HTTPS} off | |
RewriteCond %{HTTP_HOST} !^(www\.)(.*) [NC] |
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) |
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
AddType image/svg+xml svg svgz | |
AddEncoding gzip svgz |
NewerOlder