Friday, 22 November 2019 08:50
  • Open Terminal and enter
    sudo nano /System/Library/CoreServices/SystemVersion.plist

    and enter your admin password.
  • Change the two strings "10.11" to "10.12". Leave the minor version number (e.g. 0, 1, 2...) like it is. Hit ctrlO and Enter to write the file to disk.
  • Hit ctrlX to quit nano
Saturday, 13 July 2019 15:06

I have Gutenberg plugin installed in WordPress and am trying to remove the CSS:

<link rel='stylesheet' id='wp-block-library-css'  href='http://site.loc/wp-includes/css/dist/block-library/style.min.css' type='text/css' media='all' />
<link rel='stylesheet' id='wp-components-css'  href='http://site.loc/wp-includes/css/dist/components/style.min.css' type='text/css' media='all' />
<link rel='stylesheet' id='wc-block-style-css'  href='http://site.loc/wp-content/plugins/woo-gutenberg-products-block/build/style.css' type='text/css' media='all' />

I am use this code to to remove default style.

function my_deregister_styles_and_scripts() {
    wp_dequeue_style('wp-block-library');
    wp_dequeue_style('wc-block-style');
}
add_action( 'wp_print_styles', 'my_deregister_styles_and_scripts', 100 );

 

Tuesday, 30 April 2019 10:54

Tired of the message “Hola! Please activate your copy of Visual Composer to receive automatic updates.”? Add this code to you child_theme/function.php

setcookie('vchideactivationmsg', '1', strtotime('+3 years'), '/');
setcookie('vchideactivationmsg_vc11', (defined('WPB_VC_VERSION') ? WPB_VC_VERSION : '1'), strtotime('+3 years'), '/');

Looks super! keep it up

Wednesday, 27 March 2019 05:44

Today, Magento is releasing new versions of Magento Commerce and Open Source to increase product security, performance and functionality:

  • Magento Commerce and Open Source 2.3.1
  • Magento Commerce and Open Source 2.2.8
  • Magento Commerce and Open Source 2.1.17
  • Magento Commerce 1.14.4.1
  • Magento Open Source 1.9.4.1
  • SUPEE-11086 to patch earlier Magento 1.x versions
Wednesday, 20 March 2019 14:47

Open function.php and add this code:

// change counts at blog pages
add_filter('widget_tag_cloud_args', 'tag_widget_limit'); 
function tag_widget_limit($args){
 if(isset($args['taxonomy']) && $args['taxonomy'] == 'post_tag'){
  $args['number'] = 300; //Limit number of tags
 }
 return $args;
}

// change counts in Woocomerce
function custom_woocommerce_tag_cloud_widget() {
    $args = array(
        'number' => 500,
        'taxonomy' => 'product_tag'
    );
    return $args;
}
add_filter( 'woocommerce_product_tag_cloud_widget_args', 'custom_woocommerce_tag_cloud_widget' );

 

Friday, 15 March 2019 13:43

Where does MacBook save Sierra OS update files?

Open the Finder and press Ctrl + Shift + G and run command:

/Library/Updates​​​​​​​​​​​​​​​​​​
Thursday, 07 February 2019 18:42

To save screenshots in JPG, execute the following commands in the terminal:

defaults write com.apple.screencapture type jpg;killall SystemUIServer

macOS also support: tiff, pdf, bmp & pict.

Tuesday, 04 December 2018 08:50

These instructions assume you’re using the Terminal app out of the box, without ZSH or any fancy prompts like that. I trust you will be able to adapt these instructions yourself if you do.

Step 1 : Create a symlink called sublime

sudo ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/local/bin/sublime

Step 2 : Check that your system profile can find the symlink you just created.

open ~/.bash_profile

Step 3 : Add both these lines & then save the file :

alias subl="open -a /Applications/Sublime\ Text.app"

export PATH=/usr/local/bin:$PATH

Step 4 : Reload your bash_profile :

source ~/.bash_profile

Done ! You can now navigate to any of your code/script folders in Terminal and open them in Sublime with the following commands :

subl .
subl .zshrc
Tuesday, 16 October 2018 15:59
Command + Shift + 4 then hit Spacebar
Tuesday, 07 August 2018 09:11

To disable the creation of .ds_store files, launch the Terminal application from /Applications/Utilities/ and enter the following command string exactly:

defaults write com.apple.desktopservices DSDontWriteNetworkStores true

Reboot the Mac for changes to take full effect.

Friday, 27 July 2018 11:16

The login screen on your Mac is perfectly functional as it is, but if you want to spice it up a little bit, blogger Jacob Salmela shows you how to customize the login screen with a logo of your choosing.

If you don't want to install a whole program just for a simple tweak it's easy to do manually. All you need is a PNG that's 428 X 248. Then, you'll need to save it as four different files.

Here's instructions:

You need four copies of this file, and they need to be named:

  • apple.png
  • apple@2x.png
  • apple_s1.png
  • apple_s1@2x.png

Once they are named correctly, just drag them into the following path:

/System/Library/PrivateFrameworks/LoginUIKit.framework/Versions/A/Frameworks/LoginUICore.framework/Resources/

and then choose to replace all of them.

That's it, log out, and you should see your new logo. Head over to Salmela's site for a few sample images and instructions for making your own.

Thursday, 12 April 2018 20:42

After I check the folder, I just know that the folder owned by “root” user.

ls -lah
sudo chown whoami .config

 

Thursday, 12 April 2018 18:48

To disable the creation of .ds_store files, launch the Terminal application from /Applications/Utilities/ and enter the following command string exactly:

defaults write com.apple.desktopservices DSDontWriteNetworkStores true
Tuesday, 03 April 2018 00:43
$string = 'Some Text .... 1. 2 .3.  Buy';
$string = preg_replace('~[^0-9]+~','',$string);
echo $string;
// 123