Sometimes, to quickly create a prototype, I install a WordPress with WP-CLI, an homemade template, and create the navigation (using this script, for … [+]
By automating site creation on WordPress, you can also automate the creation of the site tree structure, for example for a prototype. In the example … [+]
If you use WordPress Multisite and want to remove access to signup page, you can add this code to your plugin or function file to redirect visitors … [+]
It is sometimes useful to automatically update the permalink of a post when the title is changed. This function, which you can copy into your plugin … [+]
You can populate Gravity Forms fields of several methods (like passing parameters in the form short code). Another solution is to create a function … [+]
You can force rules on field Phone Number in Gravity Forms. Simply add this code to your plugin or function file, then select in your field which … [+]
WordPress: Is there a way to change location of uploads folder for a specific custom post type only? Adapt this code to your CPT, and add it in your … [+]
How can I make one of two fields required (ie you have to indicate either the telephone or the email address)? Assuming your form ID is 5 and the 2 … [+]
To change the number of results returned by a search in wordpress, insert this code on your plugin: <?php /* * Alter number of search results per … [+]
How can I block WordPress backend access to subscriber, and redirect them to home page? Insert this code on your plugin: <?php /* * Block backend … [+]
How can I extend or limit search to specific custom post type in WordPress? To add your custom filters to the search function, add this code to your … [+]
How can I remove search function (website.com/?s=) in WordPress? Add this script to your functions file or plugin: <?php /** * Redirect Search to … [+]
WordPress version is displayed in meta generator tag, but also in css and js scripts loading (i.e. ..jquery.js?ver=5.5.1). How can I hide it? Add … [+]
Is there an easy way to retrieve the name of the parent page of a WordPress page? Add this code to your plugin or functions file: <?php /** * Get … [+]
How can I disable Gutenberg without using a plugin ? To disable Gutenberg and keep the original editor, simply add this 2 lines in functions.php or … [+]
How can I remove all comments from source code? Whether for performance reasons (less lines of code) or confidentiality reasons (hiding commented … [+]
How can I minify my html code? Minification strips a code file of all data that isn’t required in order for the file to be executed. Minified files … [+]
How can I remove panels from the WordPress Dashboard? To remove all panels, add this code to your functions.php file /** * Remove all panels from … [+]