Month: April 2018

Git Command

Go to the directory you want to initiate Git and then follow the commands: Initiate the git: git init Remove Git if you have initiated in a wrong place ( Be aware if there is another git in the subdirectory): rm -rf .git To add all the files(including subdirectory) to staging step: git add -A

After Installation of Visual Studio Code

Go to Preferences  → Settings and then paste code within {} brackets – “editor.minimap.enabled”: true, “files.autoSave”: “afterDelay”, “editor.autoIndent”: true, “editor.detectIndentation”: true, “editor.fontSize”: 14, “editor.wordWrap”: “on”,   Thanks!    

Change Custom Post Type Name Safely.

Just replace the second line’s post type names: global $wpdb; $old_post_types = array(‘old_type’ => ‘new_type’); foreach ($old_post_types as $old_type=>$type) { $wpdb->query( $wpdb->prepare( “UPDATE {$wpdb->posts} SET post_type = REPLACE(post_type, %s, %s) WHERE post_type LIKE %s”, $old_type, $type, $old_type ) ); $wpdb->query( $wpdb->prepare( “UPDATE {$wpdb->posts} SET guid = REPLACE(guid, %s, %s) WHERE guid LIKE %s”, “post_type={$old_type}”, “post_type={$type}”, …

Change Custom Post Type Name Safely. Read More »

WordPress Developers (Must Have) Plugins

The following plugins are very useful to WordPress developers. These may help you to make a standard and error-free theme and plugin. Developer. Debug Bar Query Monitor. Theme Check. User Switching. Regenerate Thumbnails. Log Deprecated Notice. RTL Tester, RTL Tester Mirror. Monster Widget. PHP Compatibility. SG Optimizer. Thank you!