Create a Personal Website in Hostinger and Get a Mega Discount Are you a new user with a small or starting business looking to create […]
Create A Folder If It Doesn’t Already Exist In WordPress Or PHP
<?php if (!file_exists(‘home/public_html/example.com/wp-content/uploads/blog’)) { mkdir(‘home/public_html/example.com/wp-content/uploads/blog’, 0777, true); } ?> According To Question: #mkdir php #check if directory exists php #how to create directory […]
WordPress Post Views Count Without Plugin
Step1″Add this code in current WordPress active theme in function.php file <?php function get_PostViews($postID){ $count_key = ‘post_views_count’; $post_count = get_post_meta($postID, $count_key, true); […]
How to Custom Pagination For Custom Post in WordPress?
There are very simple steps for Pagination for any type of Post in WordPress by Shortcode with Ajax. Write this below code in you active WordPress theme’s funcntion.php file. ie: wp-contentthemestwentytwentyfunctions.php Put this shortcode […]
How To Fix Email Spam Issue In Contact Form 7?
Some times Contact Form 7 gives Error: An error occurred while trying to send your message. Please try again later. on form submit. That time […]
How To Create A Navigation Menu In WordPress?
There are very simple steps to Create A Navigation Menu in WordPress. 1. You need to go in the Appearance » Menus page in your […]
I want to remove shortcode from content [vc_row][vc_column][vc_column_text]
$content = get_the_content(); $content = preg_replace(“~(?:[/?)[^/]]+/?]~s”, ”, $content); $content = wp_strip_all_tags($content);echo $content; ### OR ### $content = get_the_content(); $content = do_shortcode($content); echo $content;
How To Disable Automatic Updates in WordPress by Custom Plugin?
Using a simple plugin. Did you know about automatic updates on the WordPress website? Some time Some Core, Plugins, and Themes are auto-update in your […]
How to disable automatic updates in wordpress?
Write below code in current WordPress themes in function.php /wp-content/themes/twentytwenty/functions.php/* Disable Automatic Updates in WordPress */function remove_core_updates(){ global $wp_version;return(object) array(‘last_checked’=> time(),’version_checked’=> $wp_version,);}add_filter(‘pre_site_transient_update_core’,’remove_core_updates’);add_filter(‘pre_site_transient_update_plugins’,’remove_core_updates’);add_filter(‘pre_site_transient_update_themes’,’remove_core_updates’);/* .Disable Automatic Updates […]
How to Replace Text of the_content in WordPress
If you want to replace keywords and text in the_content? Add the following code to the functions.php file of your WordPress active theme OR in […]