Skip to content

Instantly share code, notes, and snippets.

View gbissland's full-sized avatar

Gareth Bissland gbissland

View GitHub Profile
@spivurno
spivurno / gw-gravity-forms-user-registration-skip-registration-for-existing-email.php
Last active September 14, 2021 13:01
Gravity Wiz // Gravity Forms // User Registration // Skip Registration if Email Exists
<?php
/**
* WARNING! THIS SNIPPET MAY BE OUTDATED.
* The latest version of this snippet can be found in the Gravity Wiz Snippet Library:
* https://github.com/gravitywiz/snippet-library/blob/master/gravity-forms/gw-user-registration-skip-registration-for-existing-email.php
*/
/**
* Gravity Wiz // Gravity Forms // User Registration // Skip Registration if Email Exists
*
* If submitted email is already registered, skip registration.
@pro-beaver
pro-beaver / style.css
Created July 28, 2016 13:27
Change Row Background Image to Background Color for mobile devices
/**
* Change Row Background Image to Background Color for mobile devices
* assign pro-row-bg-1 class to the row
*
* @author Davinder Singh Kainth
* @link http://probeaver.com/?p=348
*
*/
@media only screen and (max-width: 768px) {
@mzo84
mzo84 / Enqueue-jQuery.php
Created August 18, 2016 08:17
Wordpress Enqueue jQuery
// Put this PHP code into your functions.php le.
// This will load the jQuery library onto your page by inserting a link in the <head> section where you call wp_head.
if(!is_admin()) {
wp_deregister_script('jquery');
wp_register_script('jquery', ("http://ajax.googleapis.com/ajax/libs/
jquery/1.3.2/jquery.min.js"), false, '1.3.2');
wp_enqueue_script('jquery');
}
@katlove
katlove / functions.php
Created August 28, 2016 04:21
Remove Presets on Beaver Builder Child Theme
<?php
// Remove all of the Beaver Builder child theme presets
//(does not remove default as you should overwrite default with your child theme's default settings)
function es_remove_presets()
{
FLCustomizer::remove_preset( 'default-dark' );
FLCustomizer::remove_preset( 'classic' );
FLCustomizer::remove_preset( 'modern' );
FLCustomizer::remove_preset( 'bold' );
@GeoffEW
GeoffEW / remove_free.php
Created November 1, 2016 04:50
The Events Calendar - Make code empty if it's 0 or Free
<?php
/*
* The Events Calendar - Make code empty if it's 0 or Free
*/
add_filter ( 'tribe_get_cost', 'tribe_not_show_free', 10, 3 );
function tribe_not_show_free ( $cost, $post_id, $with_currency_symbol ) {
if ( $cost == 0 || $cost == 'Free' ) {
$cost = '';
// = Max File Size =
// =================
define( 'AI1WM_MAX_FILE_SIZE', 536870912 * 8 );
@GeoffEW
GeoffEW / hide_single_cost.php
Created January 27, 2017 01:39
Hides cost from the single event details section
<?php
/**
* Hides cost from the single event details section
*
* @param string $tpl Template relative path
*/
function tribe_single_hide_cost( $tpl ) {
if ( 'modules/meta/details.php' === $tpl ) {
add_filter( 'tribe_get_formatted_cost', '__return_empty_string' );
@jacobdubail
jacobdubail / php
Created January 30, 2017 23:44
Function to auto-set your ACF5 Pro license key
function jtd_acf_auto_set_license_keys() {
if ( !get_option('acf_pro_license') && defined('ACF_5_KEY') ) {
$save = array(
'key' => ACF_5_KEY,
'url' => home_url()
);
$save = maybe_serialize($save);
<?php
add_action( 'init', 'prefix_disable_post_page_analysis' );
/**
* Conditionally disable the Yoast Page Analysis on post and page admin edit screens.
*
* @uses prefix_is_edit_screen
* @return NULL if we're not on the right admin screen
* @author Robert Neu <http://wpbacon.com>
* @link http://auditwp.com/wordpress-seo-admin-columns/
@GeoffEW
GeoffEW / Remove_free_price_range.php
Created February 17, 2017 22:25
Advanced version of the remove free snippet
<?php add_filter ( 'tribe_get_cost', 'tribe_not_show_free', 10, 3 );
function tribe_not_show_free ( $cost, $post_id, $with_currency_symbol ) {
if ( $cost == 0 || $cost == 'Free' ) {
$cost = str_replace('Free', '', $cost);
$cost = str_replace(' - ', '', $cost);
}
return $cost;
}