// For display and saving in order details page. add_action( ‘add_meta_boxes’, ‘add_shop_order_meta_box’ ); function add_shop_order_meta_box() { add_meta_box( ‘custom_column’, __( ‘Customer Source’, ‘your_text_domain’ ), ‘shop_order_display_callback’,… Read More →
How to Encrypt and Decrypt a PHP String ?
May 25, 2022
Learn how to securely encrypt and decrypt strings in PHP with this comprehensive guide. Discover essential techniques, best practices, and step-by-step instructions to protect sensitive… Read More →
If string contains a substring in JavaScript use the following – <script type=”text/javascript”> const string = “foo”; const substring = “oo”; console.log(string.includes(substring)); // true </script>
change permissions with Chmod Use Chmod in the terminal – To change all the directories to 755 (drwxr-xr-x): find /opt/lampp/htdocs -type d -exec chmod 755… Read More →
How do I format a date in JavaScript?
May 23, 2022
To format a date use the following code – <script type=”text/javascript”> var options = { weekday: ‘long’, year: ‘numeric’, month: ‘long’, day: ‘numeric’ }; var… Read More →
Find all files containing specific text on Linux?
May 23, 2022
Use the following code to Find all files containing specific text on Linux? grep -rnw ‘/path/to/somewhere/’ -e ‘pattern’