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
jQuery(function($) { | |
var page = 1, | |
loading = true, | |
$window = $(window), | |
$content = $('body.page-template-page-browse-php #content'); | |
var load_posts = function() { | |
console.log('load_posts():: INIT'); | |
$.ajax({ | |
type : "GET", |
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
<?php | |
/* When a form is submitted, create two custom posts */ | |
function after_gform_submit($entry, $form) { | |
$isInteraction = false; | |
$interaction_type_id; | |
$supporter_email_id; | |
foreach($form["fields"] as $field) { | |
if ( $field["label"] == "Interaction Type" ) { |
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
/** | |
* @author Gabe Rose (gabe.s.rose@gmail.com) | |
* Plugin Description: | |
* This is a simple slider plugin designed to be used in WordPress Visual Composer to make easily customizable sliders. | |
* @TODO: Reduce specifity so it can actually be used separate builds. | |
*/ | |
var index = 1, | |
maxIndex = 3, | |
newIndex, |
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
//TODO: turn into jQuery function | |
$(function() { | |
$('.mix').each(function(){$(this).addClass('active');}); | |
$('.filter select').change(function() { | |
var filter = $(this).val().toLowerCase(); | |
var $filterEls = $('.mix'); | |
$filterEls.each(function() { | |
var isHidden = false; | |
var filterVal = $(this).data('filter').toLowerCase(); | |
if (filter == 'all') { |
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 ($) { | |
// An array of presentationTimeslots | |
var slots = []; | |
function presentationTimeslot(el) { | |
// So that we always have a global object scope that can't be tainted by local scopes | |
var self = this; | |
this.$el = $(el); | |
this.$parentTable = this.$el.parents('table'); |
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
import os, re, sys | |
print ("Asset Renamer v1 ::::::::::::::") | |
def replaceVersionsInFile(file): | |
#This regex matches all href and src attributes and finds version strings that either use question marks of the unicode string %3 | |
pattern = "(?:href=[\"\']?([^\"\'>]+)[\"\']?|src=[\"\']?([^\"\'>]+)[\"\']?)([\']?(?=.*%3?)[^\"\']*)|(.*(?=.*\?)[^\"\']*)" | |
fo = open(file, 'r+'); | |
text = fo.readlines() | |
fo.seek(0) | |
fo.truncate() | |
for line in text: |
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
// HTML Label plugin | |
Chartist.plugins = Chartist.plugins || {}; | |
Chartist.plugins.ctHtmlLabels = function(options) { | |
return function(chart) { | |
chart.on('draw', function(context) { | |
if (context.type === 'label') { | |
// Best to combine with something like sanitize-html | |
context.element.empty()._node.innerHTML = context.text; | |
} | |
}); |
OlderNewer