This probably isn’t useful for anyone but I’m currently using WooCommerce with WordPress and I needed a solution where a product item would automatically be added to cart on page load. The code below is what I came up with, this code will also force the user to have only 1 quantity of the item. …
Category: Coding Notes
Unable To Login To WordPress? Try This Method
WIth access to WordPress files you can force login using wp_set_current_user and wp_set_auth_cookie without knowing the password.
Example Code For Sending Transactional Emails With Mailjet
Quick example on how to send a transactional email with Mailjet API v3.1 using PHP.
Authorize.Net PHP Webhook Signature Key Check
Checking the signature key of a webhook from Authorize.Net to help reduce abuse from unwanted requests.
Send Welcome Email On Customer Group Change In Magento 1.9
I needed a solution that sends a “welcome” email to the user whenever the admin changes the “Customer Group” to one they specified.
Images Broken In WordPress After Migrating Away From WP Engine
If you tried to move away from WP Engine and noticed some of your images are broken its because WP Engine uses a custom URL to display these files in WordPress.
Set And Store Locale In Laravel 5.6 Using Middleware
I used this simple way to set and store the locale setting in Laravel 5.6 using middlewares. The code is pretty basic, if there’s a locale in the request then set the setting in session based on the parameter.