Skip to content

Instantly share code, notes, and snippets.

View thefrosty's full-sized avatar
🏖️
Santa Monica WordPress Developer

Austin Passy thefrosty

🏖️
Santa Monica WordPress Developer
View GitHub Profile
<?php
/**
* Plugin Name: Eventbrite Attendees Shortcode - Filters
* Plugin URI: https://gist.github.com/thefrosty/4cc92703b5d2bc016901
* Description: Example filters for the <a href="http://wordpress.org/plugins/eventbrite-attendees-shortcode/">Eventbrite Attendees Shortcode</a>. Made for Phillip D. @ laeventco.com
* Author: Austin Passy
* Author URI: http://austin.passy.co
* Version: 2014.10.28
* License: GPL
@thefrosty
thefrosty / 0_reuse_code.js
Last active August 29, 2015 14:08
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@thefrosty
thefrosty / edd-sl-upgrades.php
Created November 8, 2014 01:40
Upgrade a license to a higher sites count on Extendd.com for Easy Digital Downloads
<?php
if ( !defined( 'ABSPATH' ) )
exit;
function extendd_add_key_column() {
echo '<th class="edd_license_key_upgrade">' . __( 'Upgrade License', 'extendd' ) . '</th>';
}
add_action( 'edd_purchase_history_header_after', 'extendd_add_key_column' );
@thefrosty
thefrosty / edd-popular-downloads.php
Created January 23, 2015 18:15
Get popular downloads for recent XX days. Easy Digital Downloads.
@thefrosty
thefrosty / ap-show-template.php
Last active August 29, 2015 14:14
Which WordPress tempalte are you currently one? http://wp.me/p4gJ2a-Be
function ap_show_template() {
// bail early
if ( is_admin() || !is_user_logged_in() )
return;
if ( !is_admin_bar_showing() || !current_user_can( 'edit_files' ) )
return;
global $template, $wp_admin_bar;
@thefrosty
thefrosty / httpd-vhosts.conf
Created February 6, 2015 17:55
Localhost Wildcard Subdomains
<VirtualHost *:80>
DocumentRoot "/Users/austinpassy/Documents/Websites/thefrosty.net/html"
ServerName thefrosty.dev
ServerAlias thefrosty.dev *.thefrosty.dev
<Directory "/Users/austinpassy/Documents/Websites/thefrosty.net/html">
Options Indexes FollowSymLinks ExecCGI Includes
AllowOverride All
Order allow,deny
Allow from all
</Directory>
@thefrosty
thefrosty / admin.ajax.php
Created March 4, 2015 17:45
For testing perposes. This responds with 'heartbeat' when running. But when Clicking 'insert into post' or insert custom link (nav menu) among a few others the POST action never get's triggered. In my console I get 302 found, then a GET request to the home page. Example video: http://quick.as/1oovhyzj
if ( ! empty( $_POST['action'] ) && in_array( $_POST['action'], $core_actions_post ) ) {
die($_POST['action']);
add_action( 'wp_ajax_' . $_POST['action'], 'wp_ajax_' . str_replace( '-', '_', $_POST['action'] ), 1 );
}
@thefrosty
thefrosty / cron.class.php
Last active August 29, 2015 14:26 — forked from jonathonbyrdziak/cron.class.php
Wordpress Cron Job Class. Makes Cronning a snap!
<?php
/**
* @Author Anonymous
* @link http://www.redrokk.com
* @Package Wordpress
* @SubPackage RedRokk Library
* @copyright Copyright (C) 2011+ Redrokk Interactive Media
*
* @version 0.1
*/
@thefrosty
thefrosty / wp-cl-customizer.php
Created February 22, 2016 17:49
Basic WordPress customizer setting.
<?php
namespace Passy;
add_action( 'customize_register', __NAMESPACE__ . '\\customize_register' );
function customize_register( WP_Customize_Manager $wp_customize ) {
$wp_customize->add_panel( 'custom_login_settings',
array(
@thefrosty
thefrosty / Add2faMetaBox.php
Created May 4, 2017 17:32
Dovedi and WP User Profiles support.
<?php
namespace Dwnload\Plugins\Dovedi;
/**
* Class Add2faMetaBox
*
* @package Dwnload\Plugins\Dovedi
*/
class Add2faMetaBox {