In this article we are not customizing a navigation view or a navigation stack. We are simply creating a custom View to be used as a navigation bar.
In this guide, let’s explore how to set up PHP to use msmtp, a lightweight SMTP client, as its MTA.
Here’s a general outline of How to Deploy a Django project on an Ubuntu server with Nginx: Server Setup: Start by setting up an Ubuntu server. SSH into the server as the root user or a user with sudo privileges. Install Required Software: Update your system’s package list: sudo apt update Install necessary packages: sudo… Read More »How To Deploy a Django project on an Ubuntu server with Nginx
To mount an AWS S3 bucket on Ubuntu, you can use a tool called “s3fs.” S3fs allows you to access your AWS S3 bucket as if it were a local directory on your Ubuntu machine. Here’s a step-by-step guide to help you with the process: 1. Install dependencies: First, ensure you have the necessary packages… Read More »How To Mount an AWS S3 bucket on an Ubuntu Server
If you want to mount a remote hard drive on an AWS Ubuntu instance, you can use the SSHFS (SSH File System) utility. SSHFS allows you to mount a remote file system over SSH, making it accessible as if it were a local drive. Here’s how you can do it: 1. Install SSHFS on your… Read More »How To Mount a Remote hard drive on an Ubuntu server
The “Missing a temporary folder” error typically stems from incorrect server configurations. When WordPress attempts to upload files or carry out temporary operations, it requires access to a temporary folder.
Stripe Fee Calculator and Formula with custom rates. To calculate Stripe fees for a transaction, you can use the following formula: Total Fee = (Transaction Amount * Fee Percentage) + Fixed Fee. To calculate the amount to ask for with the stripe fee included, you can use the following formula: Ask For = (Transaction Amount + Fixed Fee) / (1 – (Fee Percentage / 100)).
Extract the ipa file: $ unzip -q App.ipa Extract Certificates: $ codesign -d –extract-certificates Payload/*.app $ openssl x509 -inform DER -in codesign0 -out codesign0.pem $ openssl x509 -inform DER -in codesign1 -out codesign1.pem $ openssl x509 -inform DER -in codesign2 -out codesign2.pem $ cat codesign1.pem codesign2.pem > cachain.pem Check the validity of the certificate: $… Read More »Find the expiry of a Certificate that was used to sign an .ipa App file
1. Let’s fetch the latest version of the package list from the repositories. sudo apt update 2. Upgrade the installed packages. sudo apt upgrade 3. Upgrade the distribution and reboot the server. sudo apt dist-upgrade sudo reboot 4. Let’s make sure we have the Update Manager Core installed. sudo apt install update-manager-core 5. Let’s make… Read More »How to upgrade Ubuntu server 20.04 to Ubuntu 22.04 (latest)
To convert PKCS#p12 file to a PEM file, use: openssl pkcs12 -in cert.p12 -out cert.pem -nodes -clcerts Now you will have both the certificate and key in the cert.pem file without a password. If you need the certificate and key in separate files, use this: openssl pkcs12 -in cert.p12 -out cert.pem -clcerts -nokeys openssl pkcs12… Read More »How to Convert a Apple Certificate .p12 file to a PEM File
Learn how to add two non-negative integers represented by linked lists in reverse order. Check out this Python code example.
Learn how to find indices of two numbers in an array that add up to a specific target using Python. Check out this code and examples.
Learn how to implement a stack with push, pop, and seekMin functions in Python 3 with a time complexity of O(1). Check out this code!
Python 3 code to find the Lowest Common Ancestor of a Binary Tree This is a Non Recursive solution using DFS method. class Node(): def __init__(self, val, left = None, right = None): self.val = val self.left = left self.right = right class Tree(): def __init__(self, root = None): self.root = root def lowestCommonAncestor(self, root,… Read More »Python: Lowest Common Ancestor of a Binary Tree – Non Recursive
Python 3 code to find the Lowest Common Ancestor of a Binary Search Tree def lowestCommonAncestor(root, p, q): “”” :type root: TreeNode :type p: TreeNode :type q: TreeNode :rtype: TreeNode “”” if root is None or p is None or q is None: return None if p.val > q.val: temp = p p = q… Read More »Python: Lowest Common Ancestor of a Binary Search Tree
Python program to rotate an array towards its right Inplace Method # Rotate Array def roateRight(arr, size, rotate_count): array_length = len(arr) if array_length array_length: size = array_length # Figure out effective roation count # eg: size = 10 and rotation_count = 15 # effective roation_count is 5 if rotate_count > size: rotate_count = rotate_count -… Read More »Python: Array/List Rotation – Right
Python program to rotate an array towards its left Inplace Method # Rotate Array def roateLeft(arr, size, rotate_count): array_length = len(arr) if array_length array_length: size = array_length # Figure out effective roation count # eg: size = 10 and rotation_count = 15 # effective roation_count is 5 if rotate_count > size: rotate_count = rotate_count -… Read More »Python: Array/List Rotation – Left
If you are trying to use an older version of PHP to connect MYSQL over SSL, there is a good chance that you encounter the following errors: error:0607A082:digital envelope routines:EVP_CI PHER_CTX_set_key_length: error:0906D06C:PEM routines:PEM_read_bio:no start line This is a bug in PHP, OpenSSL. This bug has been fixed in PHP version > 7.1. In case you… Read More »PHP Error:0607A082:digital envelope routines:EVP_CI PHER_CTX_set_key_length:invalid key length
The HubSpot Cookie Consent banner sets a cookie name ‘__hs_opt_out’ when you accept/decline the cookie consent. You can make use of the status of the consent to remove/allow other cookies on your website, eg: google analytics. We can get the status of the consent by adding a callback function to the ‘addPrivacyConsentListener’ event. //Add a… Read More »HubSpot Cookie Consent – Control the use of non-HubSpot cookies on your website