Skip to content

Instantly share code, notes, and snippets.

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

Jean-Francois Arseneault jfarsen

🏠
Working from home
View GitHub Profile
@helgatheviking
helgatheviking / functions.php
Last active May 6, 2019 00:15
Add Beaver Builder Support to Storefront Child Theme
<?php
function remove_page_header_for_builder() {
if( is_page_template( 'template-builder.php' ) ) {
remove_action( 'storefront_page', 'storefront_page_header' );
}
}
add_action( 'storefront_page_before', 'remove_page_header_for_builder' );
@Nilpo
Nilpo / Using Git to Manage a Live Web Site.md
Last active September 21, 2024 12:55
Using Git to Manage a Live Web Site

Using Git to Manage a Live Web Site

Overview

As a freelancer, I build a lot of web sites. That's a lot of code changes to track. Thankfully, a Git-enabled workflow with proper branching makes short work of project tracking. I can easily see development features in branches as well as a snapshot of the sites' production code. A nice addition to that workflow is that ability to use Git to push updates to any of the various sites I work on while committing changes.

Contents

@BeardedGinger
BeardedGinger / term-description.php
Created September 18, 2015 09:28
Add Term Description to event category archive
<?php
/**
* Copy the "src/views/list/content.php" file from the Core TEC plugin
*
* Paste it into your theme at "tribe-events/list/content.php"
*
* Place the following snippet in the new file within your theme wherever you
* would like the it to display.
*/
@jasperf
jasperf / A Roots Sage Theme and Dev Setup.md
Last active May 12, 2016 16:38 — forked from corradomatt/Using Roots 8.0 Process.md
Setting up Roots 8.0 (Sage) on a a Mac with Local Yosemite OSX Server and AMP. This includes setting up the server part of things #roots #wordpress #osx
@nickcernis
nickcernis / functions.php
Last active January 24, 2016 21:23
Fix for the wpMandrill WordPress plugin for blogs that send both plain text and HTML email
<?php
// Add to functions.php and leave the “Content” box unticked in Settings > Mandrill
// Be sure to omit the opening <?php tag when copying this code
// Add paragraph breaks to plain text notifications sent by Mandrill
add_filter('mandrill_payload', 'wpmandrill_auto_add_breaks');
function wpmandrill_auto_add_breaks($message) {
$html = $message['html'];
@bekarice
bekarice / edit-woocommerce-checkout-template.php
Last active September 5, 2024 01:24
Add content and notices to the WooCommerce checkout - sample code
/**
* Each of these samples can be used - note that you should pick one rather than add them all.
*
* How to use WC notices: https://github.com/woothemes/woocommerce/blob/master/includes/wc-notice-functions.php#L96
* Tutorial: http://www.skyverge.com/blog/edit-woocommerce-templates/
**/
/**
* Add a content block after all notices, such as the login and coupon notices.
*
@bramchi
bramchi / searchform.php
Last active November 1, 2022 12:07
Roots.io searchform.php template hack to get search widget working in Polylang, only searching within the active language. 'soil-nice-search' disabled btw.
<?php
/*
*
* Roots.io searchform.php template hack to fix Polylang search
*
* Note: Polylang setting 'Hide URL language info for default language' should be enabled for this to work.
* Soil-nice-search disabled in Roots.
*
*/
@natelandau
natelandau / .bash_profile
Last active September 24, 2024 06:19
Mac OSX Bash Profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
@jameskoster
jameskoster / content-team-member.php
Last active August 29, 2015 13:58
Our Team - A sample team member content template file
<?php
/**
* A template to display team member content
*/
global $post;
?>
<?php
$team_member_email = esc_attr( get_post_meta( $post->ID, '_gravatar_email', true ) );
$user = esc_attr( get_post_meta( $post->ID, '_user_id', true ) );
@christopheranderton
christopheranderton / wp-cli-update
Last active January 4, 2016 03:28
NOTE: This is a old Gist. It may work, but it can also be deprecated. | Update WP-CLI (WP-CLI itself, not a WordPress install).For use with your Terminal.app (or iTerm.app).
cd ~/.wp-cli
php composer.phar self-update
php composer.phar require 'wp-cli/wp-cli=@stable'