Mindblown: a blog about philosophy.

  • Play only 1 audio at a time

    When one page have multiple audio. we need play one audio and stop all others. This code work and tested on sermon manager for wordpress plugin. Play one audio at a time. just use this script in jQuery ready block.

  • How to customize gravity from Date format

    We can customize gravity form date formate easily by following thing. It is only output of date. In advance settings, we can make gravity form date field dropdown, icon picker etc. In my case, we need only show month and year in date picker field. You need wrap script tag open and close.

  • WordPress Ajax action conflicts with redirect restrictions

    WordPress ajax action not working when we add admin_init redirect action in wrong way. To make it work we must need to add condition to exclude ajax file like ($_SERVER[‘PHP_SELF’] != ‘/wp-admin/admin-ajax.php’) Below code is working well to exclude all non administrator redirect to my-account page and ajax action is working well.

  • WordPress settings_errors() display update message twice

    In wordpress plugin or theme settings API, when we add settings error, I face problem with display update message twice. and this is happen only when first times settings save. After a day long troubleshooting, I got this is because when update_option, it call add_option function first time. and that is the main reason to…

  • Check if current user role is..

    How to check if current user role is administrator or editor or author etc. below the function how I check it in wordpress.

  • Sort Multi-dimensional Array by Value

    We can sort multi dimensional array in php easily by any of it’s value. below are simple example I use in my code and it works great!

  • WordPress email From name with special character

    We we send email using wp_email, we can’t use special character like “‘” in from name. It shows like ' instead of single quote. But here is the solution: Just need to use like

  • Redirect an Old Domain to your New Website

    Simply enter the following code into your .htaccess file (changing the addresses in the examples below as needed) and save the changes. If there are several individual pages which have moved, just repeat as neccesary. Not sure how to access or change or .htaccess file. Read our .htaccess guide here.   Method 1: Options +FollowSymlinks RewriteEngine On…

  • How to remove Divi top menu transition with dropdown

    After a long search, I had to override core custom.min.js file into my child theme to remove top menu hover transition effect. Most important hack is custom.min.css need to replace By delay:0 is the actual change here.

  • Taxonomy breadcrumb

    We can easily add breadcrumb to taxonomy page.

Got any book recommendations?