Category: Backend

Useful WordPress SQL queries

Useful WordPress SQL queries

The best Database Editor is phpMyAdmin as for me. It is very simple and comfortable. To run SQL queries below on database choose a required database in the left sidebar and open SQL tab in the top of the right window. How to remove all posts with a custom ‘post type’ and their meta fields…

Read More Read More

Get the first & last elements of an associative array

Get the first & last elements of an associative array

This is a small tutorial on how to get the first elements of an associative array in PHP. As you probably already know, associative arrays are extremely popular in PHP, simply because they allow you to set keys/indexes that are human-friendly! Unfortunately, one of the drawbacks to using an associative array is that it can…

Read More Read More

Regex (regular expressions) cheat sheet

Regex (regular expressions) cheat sheet

The tables are not exhaustive, for two reasons. First, every regex flavor is different and we didn’t want to crowd the page with overly exotic syntax. For a full reference to the particular regex flavors you’ll be using, it’s always best to go straight to the source. In fact, for some regex engines (such as…

Read More Read More

How to increase the Menu items limit in WordPress

How to increase the Menu items limit in WordPress

Have you reached the max items menu/custom meta rows limit on WordPress? When you add more than a certain amount of menu items/custom meta rows do they just delete on saving? This tutorial will show you to increase this limit and explain what’s causing it.

rawurlencode $str Returns a string in which all…

rawurlencode $str Returns a string in which all…

rawurlencode ( $str ); Returns a string in which all non-alphanumeric characters except -_.~ have been replaced with a percent (%) sign followed by two hex digits. This is the encoding described in » RFC 3986 for protecting literal characters from being interpreted as special URL delimiters, and for protecting URLs from being mangled by…

Read More Read More