Removing Otter Pro upsell notification!

$notifications = get_option( ‘themeisle_blocks_settings_notifications’, array() ); if ( ! isset( $notifications[‘dashboard_upsell’] ) || $notifications[‘dashboard_upsell’] !== true ) { $notifications[‘dashboard_upsell’] = true; update_option( ‘themeisle_blocks_settings_notifications’, $notifications ); }Continue reading

Upload font files to media library (copy)

add_filter( ‘upload_mimes’, function( $mimes ) { $mimes[‘woff’] = ‘application/x-font-woff’; $mimes[‘woff2’] = ‘application/x-font-woff2’; $mimes[‘ttf’] = ‘application/x-font-ttf’; $mimes[‘svg’] = ‘image/svg+xml’; $mimes[‘eot’] = ‘application/vnd.ms-fontobject’; return $mimes; } );Continue reading

Add Shortcodes to the List of Conflicting Shortcodes

add_filter( ‘aioseo_conflicting_shortcodes’, ‘aioseo_filter_conflicting_shortcodes’ ); function aioseo_filter_conflicting_shortcodes( $conflictingShortcodes ) { $conflictingShortcodes = array_merge( $conflictingShortcodes, [ ‘WISDM Group Registration’ => ‘[wdm_group_users]’, ‘WISDM Quiz Reporting’ => ‘[wdm_quiz_statistics_details]’, ‘WISDM Course Review’ => ‘[rrf_course_review]’ ] ); return $conflictingShortcodes; }Continue reading

Disable Update Emails

// Disable auto-update email notifications add_filter(‘auto_core_update_send_email’, ‘disable_auto_update_emails’, 10, 4); function disable_auto_update_emails($send, $type, $core_update, $result) { if ( !empty($type) && $type == ‘success’ ) { return false; } return true; } // Disable plugin and theme update email notifications add_filter(‘auto_plugin_update_send_email’, ‘__return_false’);…Continue reading

WPBakery Shortcode for the Post Excerpt with Limited Characters [vc_post_excerpt]

// WPBakery shortcode for the post excerpt with limited characters function vc_gitem_template_attribute_post_excerpt_with_link($value, $data) { extract(array_merge(array( ‘post’ => null, ‘data’ => ”, ), $data)); $excerpt = substr($post->post_content, 0, 150) . ‘…’; return ‘ ‘ . $excerpt . ‘ ‘; } add_filter(‘vc_gitem_template_attribute_vc_post_excerpt’,…Continue reading