Categories
code WooCommerce wp-admin

Redirect after logging in based on the user role

You can redirect after logging in and use a custom URL based on the user role, like the Dashboard for admins and My Account page for customers.

Categories
code WordPress

Debugging WordPress

If you accidentally introduce a syntax or fatal error in one of your template files, you’ll probably see the dreaded white screen of death when you visit your home page. In some cases, even the admin screens will go blank. Lets see how you can fix this…

Categories
code Themes WordPress

Call a navigation menu using a shortcode

Today I came across a weird situation: I needed to place a navigation menu in the content of a page. A shortcode was the obvious solution, but there doesn’t appear to be one built in for menus. I created this one very quickly

Categories
code debugging

The semicolon;

Replace the semicolon (;) with greek question mark (;) in your friends JavaScript and watch them pull their hair out over the syntax error. 😂