WP Admin – You do not have sufficient privileges.

To harden an old WordPress site, the first thing I did was change the table prefix to something other than wp_

But that somehow turned every user from admin to subscriber, now I was locked out. And when I tried to login, it redirected me to the homepage, not the wp-admin section. Here’s what I did:

First, grab this script, put it into a php file named, force-upgrade.php , by Mark Jaquith and upload it to the same directory as your wp-config file. Then visit that directory/force-upgrade.php It will prompt you to run the script. “Hopefully that does the trick.” – But you still need to change your permission via phpMyAdmin, skip past this script to do that.

To change your role to admin, edit the following sql script to what you need and run it in the SQL tab in phpMyAdmin

Custom Styles for your WordPress WYSIWYG

A detailed list and a guide to the TinyMCE can be found here.

Functions File




Get Page with get_posts() and setup postdata

Really is a cool way to do things…


ACF Google Maps – Ways to output and format the Address in text form.

You can use Advanced Custom Fields to do some pretty cool things with Google Maps. But often you would want to spit out the address from the map in a formatted form. Here are some examples:

Simplest form:

“111 My Road, City, ST, United States”

Strip the “, United States”

“111 My Road, City, ST”

Strip the “, United States” and add a break making it multiline

” 111 My Road
City, ST ”