HTML5 .js google hosted
html5shiv.googlecode.com/svn/trunk/html5.js
or simply copy the code below and paste it into your header.php
<!--[if lt IE 9]><script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
First is you must have the browser.php in your current themes. If not, click here and create a file named browser.php in your current themes. Copy the codes below and place it into your function.php file. add_filter('body_class','browser_name_class'); function browser_name_class($classes) { $browser = new Browser(); $browser_detect_replace = str_replace( ' ', '-', $browser->getBrowser('browser_name:Browser:private') ); $browser_name = strtolower(…
Change WordPress default email notification. Mostly used in new user registration, the default is `WordPress <wordpress@yourdomain.com>`. In my case I want to change the WordPress Name to my domain name. The output will be `Anthony Carbon <info@anthonypagaycarbon.com>`. The codes below will complete your tasks. add_filter( 'wp_mail_from', 'default_wp_mail_from' ); function default_wp_mail_from( $from_email ){ if( $from_email ==…
Uncaught (in promise) TypeError: Illegal invocation error using jQuery ajax code. I don’t understand how this ajax JS parameters works but digging a deep research about the error shows me some correct solution. Here’s the code of mine that has `Uncaught (in promise) TypeError: Illegal invocation` error. JS code that has `Uncaught (in promise) TypeError:…
To replace the default WordPress jquery ( http://192.185.73.118/~anthonycarbon/wp-includes/js/jquery/jquery.js ) library with the Google hosted jquery library, copy the below codes and paste it into your functions.php file. The7 WordPress theme dequeue script. Example is `dt-above-fold`. add_action( 'wp_enqueue_scripts', 'my_deregister_javascript', 20 ); add_action( 'wp_print_scripts', 'wp_print_scripts_deregister', 100 ); function my_deregister_javascript() { if ( ! is_admin() && isset( $_GET['wp_print_scripts']…
jQuery( document ).ready( function(){ var custom_timeout = ( function() { var timers = {}; return function ( callback, ms, uniqueId ) { if ( !uniqueId ) { uniqueId = "Don't call this twice without a uniqueId"; } if ( timers[uniqueId] ) { clearTimeout ( timers[uniqueId] ); } timers[uniqueId] = setTimeout( callback, ms ); }; })();…
How to add rtMedia custom settings just like the example image above? Just add the codes to your functions.php of your theme. add_filter( 'rtmedia_add_settings_sub_tabs', 'wdes_music_rtmedia_pro_settings_tabs_content' ); function wdes_music_rtmedia_pro_settings_tabs_content( $tabs ){ $tabs[] = array( 'href' => '#rtmedia-music-genre', 'icon' => 'dashicons-admin-tools', 'title' => esc_html__( 'Music Genre' ), 'name' => esc_html__( 'Music Genre' ), 'callback' => 'wdes_music_genre_settings_callback', );…