Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View jamesmacwhite's full-sized avatar

James #FFFFFF jamesmacwhite

View GitHub Profile
@jamesmacwhite
jamesmacwhite / ubuntu-deluge-daemon
Last active August 29, 2015 14:06
Ubuntu Deluge daemon that's compatible with Raspberry Pi devices - http://dev.deluge-torrent.org/wiki/UserGuide/InitScript/Ubuntu
#!/bin/sh
### BEGIN INIT INFO
# Provides: deluge-daemon
# Required-Start: $local_fs $remote_fs
# Required-Stop: $local_fs $remote_fs
# Should-Start: $network
# Should-Stop: $network
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Daemonized version of deluge and webui.
@jamesmacwhite
jamesmacwhite / cta-buttons-cross-client-email.html
Last active August 29, 2015 14:06
Cross Client Email Call to Action (CTA) buttons without images
<!--
Cross client CTA buttons in email
Originally taken from: http://www.industrydive.com/blog/how-to-make-html-email-buttons-that-rock/
Additions and modifications made due to certain behaviours in email clients
-->
<!--
Method #1: Buttons that span the entire space with fixed width/height/line-height
@jamesmacwhite
jamesmacwhite / outlook-table-cells-css-inheritance.html
Created September 18, 2014 20:42
CSS inheritance on table cells in Outlook desktop clients
<!--
CSS inheritance on table cells in Outlook
Applying CSS to a table cell that has two or more cells within the same table will cause some CSS
to be applied to all of the table cells in Outlook desktop clients.
-->
<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="left" valign="top" style="padding-bottom:5px;">Cell 1 with 5px padding on the bottom</td>
@jamesmacwhite
jamesmacwhite / background-size-test.html
Last active August 29, 2015 14:07
When background-size fails (Windows 8 mail app)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width" />
<title>background-size CSS3 test</title>
<style type="text/css">
@jamesmacwhite
jamesmacwhite / outlook-image-test.html
Last active August 29, 2015 14:09
Outlook image resize test
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width" />
<title>Outlook Image Test</title>
<style type="text/css">
@jamesmacwhite
jamesmacwhite / LG-37LS5600.xml
Created January 26, 2016 18:32
Plex DLNA profile for LG-37LS5600
<?xml version="1.0" encoding="utf-8"?>
<!--
Profile Name: LG-37LS5600.xml
Description: Plex DLNA Profile
Version: 0.1
http://www.lg.com/uk/tvs/lg-37LS5600-led-tv
Changelog:
0.1:
@jamesmacwhite
jamesmacwhite / blocked-domains-list-uk-isps.txt
Last active March 12, 2016 06:43
List of domains that are blocked by the major ISP's in the United Kingdom on copyright and trademark infringement grounds.
#
# blocked-domains-list-uk-isps.txt
# Revision: 2.2.4
# Last Updated: 12/03/2016
# License: WTFPL - http://www.wtfpl.net (Seriously, its a text file, do what you want)
#
# Description:
# A simple list of domains in ascending order that are blocked in the United Kingdom on "copyright and trademark infringement" grounds
# This list tries to capture all domains blocked (including variants) and major proxy sites that are also blocked
# The www. prefix is not included on any entry, even though some may use it as the preferred domain
@jamesmacwhite
jamesmacwhite / dotmailer-ee-floated-three-column.html
Last active April 27, 2016 07:51
Floated table columns with dotmailer Easy Editor
<!DOCTYPE html>
<html>
<head>
<title>dotmailer Easy Editor floated table three column layout</title>
</head>
<body>
<!-- QUEUE DEVELOPER NOTES! -->
<h1>Floated table three column layout</h1>
<p>A way to create a three column layout with with floated tables that is compatible with the dotmailer Easy Editor.</p>
@jamesmacwhite
jamesmacwhite / office-365-owa-anchors.html
Last active May 1, 2018 02:54
Styling anchors in Office 365 (OWA). What a pain in the @$$!
<!--
A standard anchor in your email campaign
How Office 365 (OWA) renders it:
** Anchor colour isn't applied and uses default colour state of the browser the email is viewed in
** Link underline is present and is the same colour as the default colour state of the browser viewed in
-->
<a href="http://github.com" style="color:#ff0000; text-decoration:none;">Awesome Sauce</a>
@jamesmacwhite
jamesmacwhite / dd-wrt-inadyn-entware.md
Last active May 21, 2018 18:52
Using the newer version of inadyn on DD-WRT

Using the Entware inadyn package on DD-WRT

Dynamic DNS is a great tool for being able to keep one or more services that rely on a specific DNS name record being accurate. In most cases, DDNS is useful for something like your home ISP IP address which is often dynamic or "sticky". Unless provided (or you pay for the priviledge), residenital ISP broadbrand plans don't usually offer static IP.

DD-WRT includes DDNS (inadyn), but there is one problem. It's very old. DD-WRT includes the version 1.96-ADV. While having older software isn't ideal there is one key area that is a potential security issue. SSL support. The standard DDNS implementation in DD-WRT means you are sending your DNS update request over plaintext. This is bad. Being able to sniff credentials for your chosen DNS provider over the wire means you are wide open to someone being able to intercept and modify the request. In addition, the crendentials used may also be tied to a service multiple services. While it would require some effort and en