Using Select2 with ajax with CMB2 repeating groups

No idea if the title makes sense. I wanted a Select2 which uses a remote data source queried via ajax with a CMB2 repeating group so made a plugin to understand it better. It’s pretty heavily commented so I don’t forget why I did what I did. There are definitely a few if not many ways to do this, this is not the definitive guide.

Continue reading “Using Select2 with ajax with CMB2 repeating groups”

Bulk deleting users in WordPress multisite

So I have over 10,000 spam users and need to delete them1. The bulk delete in multisite only does 20 at a time and is somewhat slow so I wanted a better way to delete them all. This could be a massive mistake, if you are reading this because you need the same thing, you absolutely must thoroughly test it to see if it works for you. It’s unforgiving.

Continue reading “Bulk deleting users in WordPress multisite”

Gutenberg wish list

Ok, this is without really looking at it so maybe it has these.

  1. identifiable non-global blocks (so not these: because I want to maybe use postmeta with a block? I don’t know, I have this vague idea that I’m too lazy to articulate atm. ok this wasn’t bad, I’ve done this.
  2. the ability to limit blocks shown
  3. the ability to make templates which need to be filled in so the author has to stick to the blocks in the editor and can’t add or remove or whatever

These are mine. You might have different ones.  ☺️

edit (same day, a few hours later): Look at this for numbers 2 and 3 in the list! Whooo!

Improving Gravatar (the service)

The problem:

Gravatar hashes are somewhat easy to crack. Websites are super easy to scrape. Sites with Gravatar urls in the img-src or profile link make it trivial to generate lists of hashes to crack. Other data available on sites and in Gravatar profiles can be used to generate targeted wordlists which make cracking a large proportion of the hashes much quicker, in seconds rather than days.

Continue reading “Improving Gravatar (the service)”

Windstream compatible modem for a non-bonded connection

When my Windstream modem was repeatedly power cycling when trying to connect, tech support said this was the modem letting me know it was damaged and needed to be replaced. They offered to rent me a modem for $10/month but oh my god no, why would I do that? This one lasted me over 10 years.

Continue reading “Windstream compatible modem for a non-bonded connection”

A Slack bot that gets the last three posts from a WordPress site

This Glitch project grabs the latest three posts for WordPress sites which are using either the WP REST API or the version via Jetpack. It uses MongoDB for persistence. It’s not super exciting or well written but a fairly effective way to mindlessly try sites on Slack and see if they have the WP API somewhere when you’re a bit bored. (Try Glitch. It’s fun.)

Keeping your email address safe on Gravatar enabled sites (or if you don’t know if it is or not)

Do you consider your email address to be private information but use it to register and comment on WordPress powered sites? Many WordPress sites use Gravatar to provide the avatars on comments and user lists and this can be an issue if you do.

Continue reading “Keeping your email address safe on Gravatar enabled sites (or if you don’t know if it is or not)”

How does WordPress know if a pending post hasn’t been published yet?

If WordPress has a newly created pending post, when you publish it the timestamp on the post is set at the time of publishing. If you publish a post, then set the post status to pending, the timestamp does not update when you re-publish it. How does it know? And why does it matter?

Continue reading “How does WordPress know if a pending post hasn’t been published yet?”