Skip to content

Instantly share code, notes, and snippets.

View electricbrick's full-sized avatar

Tom Finley electricbrick

View GitHub Profile
@billerickson
billerickson / genesis-custom-loop-pagination.php
Created July 31, 2012 15:59
Genesis custom loop with pagination
<?php
/* Template Name: Test */
/**
* Genesis custom loop
*/
function be_custom_loop() {
global $post;
// arguments, adjust as needed
@joshualynch
joshualynch / my-sites-custom-super-admins.php
Created September 17, 2012 05:31
Replace WordPress "My Sites" Menu for Super Admins
<?php
/*
* Disable My Sites menu in toolbar for Super Admins & replace with custom menu
* Docs: http://codex.wordpress.org/Class_Reference/WP_Admin_Bar
*/
function jpl_remove_my_sites( $wp_admin_bar ) {
if (current_user_can('manage_network'))
@rianrietveld
rianrietveld / wpacc_skip_links.css
Created September 25, 2012 09:52
WordPress Genesis Accessible skip links
@plapier
plapier / Typekit font mixin.scss
Created October 31, 2012 18:39
Sass Mixin for typekit variation-specific font-family names
Sass Mixin for typekit variation-specific font-family names
Typekit IE6-8 Support (http://help.typekit.com/customer/portal/articles/6855-Using-multiple-weights-and-styles)
$lucida-grande: "Lucida Grande", Tahoma, Verdana, Arial, sans-serif;
$georgia: Georgia, Cambria, "Times New Roman", Times, serif;
// Must include fallbacks for EACH typekit font — set them each as variables
//************************************************************************//
$typekit-fonts: "source-sans-pro", "ff-tisa-web-pro"; // index [1, 2]
@malarkey
malarkey / Contract Killer 3.md
Last active May 24, 2024 23:38
The latest version of my ‘killer contract’ for web designers and developers

When times get tough and people get nasty, you’ll need more than a killer smile. You’ll need a killer contract.

Used by 1000s of designers and developers Clarify what’s expected on both sides Helps build great relationships between you and your clients Plain and simple, no legal jargon Customisable to suit your business Used on countless web projects since 2008

…………………………

/**
* Post Authors Post Link Shortcode
*
* @author Bill Erickson
* @link http://www.billerickson.net/wordpress-post-multiple-authors/
*
* @param array $atts
* @return string $authors
*/
function be_post_authors_post_link_shortcode( $atts ) {
@jo-snips
jo-snips / custom-tribe-title.php
Last active September 5, 2018 07:30
The Events Calendar: Filter Tribe Events Title
add_filter('tribe_get_events_title','custom_get_events_title');
function custom_get_events_title( $depth=true ) {
global $wp_query;
$tribe_ecp = TribeEvents::instance();
$title = __('Class Schedule', 'tribe-events-calendar');
// TODO: Use the displayed dates for the title
/*
if ( tribe_is_upcoming() || isset( $_REQUEST['tribe-bar-date'] ) ) {
@jo-snips
jo-snips / genesis-events-titles.php
Created November 26, 2012 20:56
The Events Calendar: Set Event Related Page Titles in Genesis
/*-----------------------------------------------------------------------------------*/
/* Set Post Titles in Genesis
/*-----------------------------------------------------------------------------------*/
add_action('genesis_post_title','custom_do_post_title');
function custom_do_post_title() {
$tribe_ecp = TribeEvents::instance();
$title = get_the_title();
if ( strlen( $title ) == 0 )
@NicktheGeek
NicktheGeek / agentpress.php
Created January 10, 2013 20:27
Change AgentPress feature listing widget output
<?php
add_filter( 'agentpress_featured_listings_widget_loop', 'child_featured_listings_widget_loop' );
/**
* This code will replace the "," left behind in AgentPress feature listing widget after
* the listing detail IDs have been changed.
* Change the IDs to suit your needs.
*/
function child_featured_listings_widget_loop( $loop ){
@unix7
unix7 / gist:4510595
Last active March 21, 2018 14:57
Basic CSS For Formidable Form
/* Form */
.with_frm_style label{
font-size:12px;
float:none;
text-align:left;
margin:0;
padding:0;
width:auto;
}