Skip to content

Instantly share code, notes, and snippets.

View GiacomoLaw's full-sized avatar
🦆

Giacomo Lawrance GiacomoLaw

🦆
View GitHub Profile
# caching
<IfModule mod_expires.c>
ExpiresActive On
# Images
ExpiresByType image/jpeg "access plus 1 year"
ExpiresByType image/gif "access plus 1 year"
ExpiresByType image/png "access plus 1 year"
ExpiresByType image/webp "access plus 1 year"
ExpiresByType image/svg+xml "access plus 1 year"
//
$("input[value='hello'][type='checkbox']").change(function(){
$("input[value='hello'][type='checkbox']").prop("checked", $(this).prop("checked"));
});
@GiacomoLaw
GiacomoLaw / checkbox_save.js
Created March 14, 2017 14:23
Saves the status of checkboxes to your local disk
var i, checkboxes = document.querySelectorAll('input[type=checkbox]');
function save() {
for (i = 0; i < checkboxes.length; i++) {
localStorage.setItem(checkboxes[i].value, checkboxes[i].checked);
}
}
function load_() {
for (i = 0; i < checkboxes.length; i++) {
#Import Google notes to Evernote
#!/bin/bash
# Must be run in the folder containing the desired Google Notes backup
BASE=/tmp/gnotes
rm -Rf $BASE
IFS=$'\n'
for N in `find ./ -maxdepth 1 -mindepth 1 -type d `
do
@GiacomoLaw
GiacomoLaw / aircraft_ids
Last active December 6, 2016 11:40 — forked from carmichaelalonso/aircraft_ids
Infinite Flight Livery/Aircraft ID list for third-party developers (Dec 2016 Update)
A10
---
81d9ccd4-9c03-493a-811e-8fad3e57bd05:373cc897-32d5-4e3e-84b3-96103d6cac0e:A-10:Generic:A-10:Generic
A318
---
982dd974-5be7-4369-90c6-bd92863632ba:1d7dff42-46a5-4c47-a46c-bd39ab9cea8d:Airbus A318:Generic:Airbus A318:Generic
982dd974-5be7-4369-90c6-bd92863632ba:291d9656-eb0a-4608-a8dc-268ac031a448:Airbus A318:Infinite Flight (2015):Airbus A318:InfiniteFlight2015
982dd974-5be7-4369-90c6-bd92863632ba:20bcdb6b-854f-44ee-addc-b30fb5acfe05:Airbus A318:ACJ Livery 1:Airbus A318:ACJ_1
982dd974-5be7-4369-90c6-bd92863632ba:3390fa9c-61f7-4c10-97c4-d0f25a526dfd:Airbus A318:ACJ Livery 2:Airbus A318:ACJ_2
@GiacomoLaw
GiacomoLaw / wlscheduling.md
Created November 29, 2016 14:06
Wunderlist scheduling idea feature

The user has a task, that is due for a date. However, the user wants this task to appear in the 'Today' view earlier than the due date. Therefore, they set the scheduling date to the date they want to do it.

For example, I have a piece of work set. The teacher says it must be in on the 11/12/2016. However, I want to do it before that date, so I set the scheduling date for 02/12/2016, and it appears on that date whilst the due date is still left preserved.