View functions.php
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 ( is_admin() ) : | |
add_action( 'current_screen', function( $hook ) | |
{ | |
if ( 'edit' == $hook->base ) : | |
add_action( 'admin_print_styles', function() |
View plugins-handler.js
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
(function($){$(function(){ | |
class prefixUpdater | |
{ | |
setProperties() | |
{ | |
this.red = '#fff0f0'; | |
this.green = '#f1fff0'; |
View functions.php
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_action( 'login_footer', function() | |
{ | |
$imprint = site_url( 'imprint' ); // change imprint with your page-slug | |
$privacy = site_url( 'privacy' ); // change privacy with your page-slug | |
echo <<<LINKS |
View functions.php
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 layouts to the Divi library and get the ID from the corresponding URL | |
// To get your results, you can add a shortcode to text fields as follows: [divi-layout id="7"] | |
add_shortcode( 'divi-layout', function( $atts ) | |
{ | |
$atts = shortcode_atts( [ 'id' => '', ], $atts ); |
View functions.php
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 this snippet to your themes "functions.php" to order the projects by title | |
add_action( 'parse_query', function( $vars ) | |
{ | |
if ( 'project' == $vars->query['post_type'] ) | |
{ |
View functions.php
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 | |
// Here you can see how to combine "Divi - Filterable Blog Module" with the free plugin "Events Manager": https://wordpress.org/plugins/events-manager/ | |
// Just add these snippets to your themes functions.php and change them according to your needs. | |
// Combine Event Manager with "Divi – Filterable Blog Module" by changing the $query_args | |
// If you use it like this, the sorting starts with the current event and past events will be hidden automatically | |
add_filter( 'dfbm_query_args_output', function( $query_args ) | |
{ |
View class-license.php
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 allow direct access | |
* | |
* @since 1.0.0 | |
*/ | |
if ( ! defined( 'ABSPATH' ) ) die( 'Don\'t try to load this file directly!' ); | |
/** | |
* Indikator Design - EMP License Key Registration |
View open-mail.js
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
(function($){ | |
$(function(){ | |
"use strict"; | |
$( '#e-placeholder' ).find( 'img' ).on( 'click', function() | |
{ | |
var link = $( '<a />', | |
{ | |
id : 'e-remove', | |
href : 'mailto:my-mail@my-domain.com?Subject=I want to get in touch with you!&body=My message to you.', |
View functions.php
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 | |
// Prevent Downgrading | |
add_filter( 'woocommerce_subscriptions_switch_is_identical_product', function( $is_identical_product, $product_id, $quantity, $variation_id, $subscription, $item ) | |
{ | |
if ( wc_get_product( (int) $product_id )->get_price() < $item->get_product()->get_price() ) | |
{ | |
$is_identical_product = true; |
View functions.php
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 | |
// This is a fork of the shortcode-finder described in this useful post: http://www.wpbeginner.com/wp-tutorials/how-to-find-and-remove-unused-shortcodes-from-wordpress-posts/ | |
// Just add the snippet in your themes functions.php. You can use this shortcode in a post or page, as shown in the following example: | |
// [find_shortcode name='et_pb_dfbm_blog'] | |
add_shortcode( 'find_shortcode', function( $atts, $content = false ) | |
{ |
NewerOlder