Skip to content

Instantly share code, notes, and snippets.

View eheiser's full-sized avatar
🏠
Working from home

Erwin Heiser eheiser

🏠
Working from home
View GitHub Profile
@sbone
sbone / foundation-5-bookmarklet-styles.css
Last active August 29, 2015 14:18
CSS for JS bookmarklet that shows which breakpoint Foundation 5 is reading
#foundation-breakpoint-indicator:before {
content: 'NULL';
display: block;
position: fixed;
top: 0;
left: 50%;
margin-left: -50px;
width: 100px;
background-color: blue;
text-align: center;
@jmuspratt
jmuspratt / Craft CMS: Sharing Links
Last active August 29, 2015 14:20
Twitter, Linkedin, Facebook, and Email
@jamiepittock
jamiepittock / gist:1360275
Created November 12, 2011 09:09
Update profile form
{embed="layout/_start"
body_class=""
section=""
{!-- BETTER META OPTIONS BELOW --}
title=""
title_suffix=""
title_prefix=""
description=""
keywords=""
robots_index=""
@jamiepittock
jamiepittock / gist:1360274
Created November 12, 2011 09:07
Update password form
{embed="layout/_start"
body_class=""
section=""
{!-- BETTER META OPTIONS BELOW --}
title=""
title_suffix=""
title_prefix=""
description=""
keywords=""
robots_index=""
@moonbeetle
moonbeetle / ee_stash_zurb_block-grids.txt
Created May 24, 2012 14:42
EE-Stash-ZURBFoundation-block-grid-images
{!--
Conditionally output up to three images in a Foundation block-grid
Assumptions:
* Channel "Pages" (pages)
* Custom field "cf_page_images"
* Addons : P&T Assets, Croxton's Stash, Switchee
* Assets field set to allow multiple images
* Template uses ZURB Foundation framework
* Limit is set to three images, but ZURB Foundation block-grids go up till five
--}
@jamiepittock
jamiepittock / ExpressionEngine template
Created November 23, 2012 11:48
Inject events from low_events:entries into low_events:calendar cells
{exp:low_events:calendar
events_field="cf_events_date_time"
date="{freebie_4}"
}
<table class="calendar" cellspacing="0" cellpadding="0">
<thead>
<tr id="month_pager">
<th colspan="1" class="previous"><a href="{structure:page:uri}
on/{prev_month_url}" title="{prev_month format='%F %Y'}">&larr;</a></th>
<th colspan="5" class="month_title"><a href="{structure:page:uri}
@davist11
davist11 / pl.plugin.php
Created November 27, 2012 21:36
Picturefill method from plugin
Output the picturefill HTML, so you don't have to repeat it all over the templates.
- Param: big_img, src for big image
- Param: small_img, src for small image
- Param: alt, alt attribute for image
- Param: media_query, media query to use, defaults to (min-width: 600px)
- Param: class, class for wrapper, defaults to hero
Example Usage:
{exp:vl:picturefill
big_img="{custom_field_name}"
@davist11
davist11 / ext.php
Last active December 16, 2015 22:09
EE Entry previewing
<?php
public function sessions_end($session)
{
if ($session->userdata['can_access_cp'] === 'y') {
$new_global_vars['gv_can_preview'] = TRUE;
} else {
$new_global_vars['gv_can_preview'] = FALSE;
}
@getify
getify / gist:675496
Created November 13, 2010 17:18
detecting if flash plugin is installed
var _flash_installed = ((typeof navigator.plugins != "undefined" && typeof navigator.plugins["Shockwave Flash"] == "object") || (window.ActiveXObject && (new ActiveXObject("ShockwaveFlash.ShockwaveFlash")) != false));
@low
low / low-search-ajax.js
Last active October 18, 2020 13:21
Using Low Search for ExpressionEngine with Ajax. Change any of the three variables on top to suit your needs. Tested with jQuery 1.9.0.
(function($){
$(function(){
var $form = $('#search'), // Search form
$target = $('#results'), // Results container
rp = 'search/ajax-results'; // Template for results only
// Function to execute on success
var success = function(data, status, xhr) {
$target.html(data);
};