ACF: Organization

/** * Organization & Local Business Schema Field Registration */ add_action(‘acf/init’, function() { if (!function_exists(‘acf_add_local_field_group’)) { return; } acf_add_local_field_group(array( ‘key’ => ‘group_organization_schema’, ‘title’ => ‘Organization & Business Information’, ‘fields’ => array( // Basic Organization Info array( ‘key’ => ‘field_org_basic’, ‘label’…Continue reading

Block WPCode Conversion Pixels Facebook

add_filter(‘wpcode_get_snippets_for_location’, function( $snippets, $location) { if ( ‘site_wide_header’ !== $location ) { return $snippets; } // Let’s remove any snippet with the id of pixel_facebook. $snippets = array_filter( $snippets, function( $snippet ) { return ‘pixel_facebook’ !== $snippet->id; } ); return…Continue reading

cmplz-show-banner

/** * Show the banner when a html element with class ‘cmplz-show-banner’ is clicked */ function cmplz_show_banner_on_click() { ?>Continue reading

(cloud) r2c on Call Param

//script: r2c on Call Param with Enhanced Tracking //ver 2.6 if (!defined(‘ABSPATH’)) exit; // Static phone number override – if set, will bypass all other functionality $static_phone_number = ‘8001234567’; // Set your phone number here, e.g. ‘8001234567’ // If static…Continue reading

Add Another Meta Keyword to Each Post

add_filter( ‘aioseo_keywords’, ‘aioseo_filter_keywords’ ); function aioseo_filter_keywords( $keywords ) { if ( is_singular() ) { $keywords = explode( ‘,’, $keywords ); array_push( $keywords, ‘anotherkeyword’ ); $keywords = implode( ‘,’, $keywords ); } return $keywords ; }Continue reading

change search url

function wpb_change_search_url() { if ( is_search() && ! empty( $_GET[‘s’] ) ) { wp_redirect( home_url( “/search/” ) . urlencode( get_query_var( ‘s’ ) ) ); exit(); } } add_action( ‘template_redirect’, ‘wpb_change_search_url’ );Continue reading