Skip to content

Instantly share code, notes, and snippets.

@iso100
iso100 / gumby_global-columns.scss
Created October 15, 2013 18:55
A function for use with Gumby framework that helps calculate the % width of a column in global columns when nested inside another column
@function global-columns($desired_cols, $container_cols, $hybrid-grid: false){
@if ($hybrid-grid == true) {
@return (100% * (columns($desired_cols, true) / columns($container_cols, true)));
}
@else {
@return (100% * (columns($desired_cols) / columns($container_cols)));
}
}
@iso100
iso100 / Statamic_related_content.html
Created December 12, 2013 22:00
Fieldset yaml and template code for rendering related entries in Statamic.
@iso100
iso100 / .gitignore
Last active August 29, 2015 13:56
Better Statamic .gitignore rules
# Statamic files #
######################
_cache/*
!_cache/index.html
_logs/*
!_logs/index.html
@iso100
iso100 / sql update
Created March 10, 2014 15:03
Update field based on match on fields in temp table
UPDATE exp_pw_landingpages epw
SET epw.mailcode =
(SELECT mailcode FROM temp WHERE website = epw.website and subdir = epw.subdir)
@iso100
iso100 / implicit_cookie_code.txt
Last active August 29, 2015 13:57
Sample code for EU cookie law compliance
@iso100
iso100 / default.html
Created July 3, 2014 19:01
Homepage template showing a gallery item
<div class="row">
<div class="eight columns">
<h2>Photography by Andrew Mosedale</h2>
<div class="row">
<div class="eight columns">
{{ content }}
</div>
<div class="four columns">
<div class="example-image">
{{ get_content from="/gallery" }}
@iso100
iso100 / page.md.yaml
Last active August 29, 2015 14:03
yaml for gallery page
---
title: Gallery
_fieldset: gallery
_template: gallery
gallery:
-
photo: '{{ _site_root }}assets/img/dream.jpg'
caption: Dream
-
photo: '{{ _site_root }}assets/img/reborn.jpg'
@iso100
iso100 / grunt-issues.txt
Created February 13, 2015 21:46
Errors when trying to run grunt serve
~/D/w/A/d/s/p/b/r/FE-static-templates ❯❯❯ grunt serve ⏎
Loading "autoprefixer.js" tasks...ERROR
>> Error: Cannot find module 'caniuse-db/data'
Loading "sass.js" tasks...ERROR
>> Error: `libsass` bindings not found. Try reinstalling `node-sass`?
Running "serve" task
Warning: Task "autoprefixer" not found. Use --force to continue.
Aborted due to warnings.
2919df34-e165-4b2e-abae-c866be537f9e 10:19:35 AM: debug Parse returned Aeon Energy Monitor power is 1709 W
2919df34-e165-4b2e-abae-c866be537f9e 10:19:35 AM: debug state - energy null null, power 2017-07-20T14:06:40+0000
2919df34-e165-4b2e-abae-c866be537f9e 10:19:35 AM: debug zwaveEvent MeterReport(meterType: 33, meterValue: [0, 26, 21, 88], precision: 3, scale: 2, scaledMeterValue: 1709.400, size: 4)
2919df34-e165-4b2e-abae-c866be537f9e 10:19:08 AM: error groovy.lang.GroovyRuntimeException: Ambiguous method overloading for method java.lang.Float#multiply.
Cannot resolve which method to invoke for [null] due to overlapping prototypes between:
[class java.lang.Character]
[class java.lang.Number] @ line 106
2919df34-e165-4b2e-abae-c866be537f9e 10:19:08 AM: debug Resetting Energy
2919df34-e165-4b2e-abae-c866be537f9e 10:19:08 AM: debug state - energy null null, power 2017-07-20T14:06:40+0000
2919df34-e165-4b2e-abae-c866be537f9e 10:19:08 AM: debug zwaveEvent MeterReport(meterType: 33, meterValue: [0, 0, 74,
@iso100
iso100 / pb.livechat.js
Created July 25, 2018 18:39
PB Livechat Javascript
'use strict';
var pb = pb || {};
(function() {
pb.namespace = function(nsString) {
var parts = nsString.split('.'),
parent = pb,
i;
if (parts[0] === 'pb') {