This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add genesis layout classes to the Block Editor. | |
// File lives in the theme's /js/ folder. | |
wp.domReady(function () { | |
yourTheme.updateLayoutClass(); | |
var layouts = document.querySelector(".genesis-layout-selector"); | |
if( layouts ) { | |
layouts.addEventListener("input", function (e) { | |
yourTheme.updateLayoutClass(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'jet-engine/listings/allowed-callbacks', 'jet_add_attachment_callback', 10, 2 ); | |
function jet_add_attachment_callback( $callbacks ) { | |
$callbacks['jet_get_attachment_file'] = 'Get attachment file by ID'; | |
return $callbacks; | |
} | |
function jet_get_attachment_file( $attachment_id ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'template_redirect','tu_add_elementor_filter', 999 ); | |
function tu_add_elementor_filter() { | |
if ( in_array( 'elementor-page elementor-page-' . get_the_ID(), get_body_class() ) ) { | |
add_filter( 'body_class', 'tu_add_elementor_classes' ); | |
add_filter( 'generate_show_title','__return_false' ); | |
} | |
} | |
function tu_add_elementor_classes( $classes ) { | |
$classes[] = 'full-width-content'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Elementor Form Additional Webhook | |
* Plugin URI: https://gist.github.com/csalzano/dfd754e0fe8b6ac10731fad8f257c0bf | |
* Description: Adds a second Webhook to an Elementor form | |
* Version: 1.0.1 | |
* Author: Corey Salzano | |
* Author URI: https://breakfastco.xyz/ | |
* License: GPLv2 or later | |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** Do NOT include the opening php tag */ | |
/** | |
* Do not load a list of Google Fonts in Astra | |
* | |
* @link https://gist.github.com/deckerweb/528e9f64f09b15ed4d6729b77d87dc78 | |
* @author David Decker - DECKERWEB | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Use one of the filters. Not multiple... | |
* I'd use the third. | |
*/ | |
add_filter( 'wp_get_attachment_image_attributes', function ( $attr ) { | |
if ( isset( $attr['class'] ) && 'custom-logo' === $attr['class'] ) { | |
$attr['itemprop'] = 'image'; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if(!defined('ABSPATH')) { die(); } | |
/* | |
Plugin Name: Admin Bar for WeGlot | |
Plugin URI: https://gschoppe.com | |
Description: Adds an admin bar link to translate any page on your site | |
Version: 0.1.0 | |
Author: Greg Schoppe | |
Author URI: https://gschoppe.com | |
Text Domain: weglotadminbar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Filter out "archive" from archive page title | |
function wpldn_remove_archive_text( $value, $original_value, $params ) { | |
$value = str_replace( $params->'Archives: ', ' ', $value ); | |
return $value; | |
} | |
add_filter( 'ast-advanced-headers-title', 'wpldn_remove_archive_text', 10, 3 ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Ensure Paid Memberships Pro compatibility when using the Elementor Page Builder: | |
* https://wordpress.org/plugins/elementor/ | |
* | |
* Your administrator-level account must have a Membership Level in order to edit all of the pages assigned | |
* under Memberships > Pages. | |
* | |
* You must also set a Custom Field on the Membership Checkout page with the key 'pmpro_default_level' and | |
* value of a level ID in order to properly edit your Membership Checkout page using Elementor. |