-
Block Editor: Show Gutenberg Context Menus on Right Click
by
When using the WordPress Gutenberg block editor, it’d sure be nice to right-click on an element in the outline and instantly see the context menu. This snippet makes it possible.
-
Post Content: Replace & Wrap Specific Keywords in Custom Link
by
If you often type certain text and want it to always link to the same place everytime it appears on your site, this can help. You provide a key=>value pair in the array here: And anytime a post is viewed, the script will search for the text on the left and wrap it in a…
-
Analytics: Add Microsoft Clarity in wp_head on WordPress Production sites
by
This adds your Microsoft Clarity Analytics ID to the head of your public-facing WordPress pages (not your admin pages) and only for users who aren’t logged-in. Replace the XXXXXXXXX with your ID and you’re good to go. By default, it assumes you want to add the script. However, if you’re using my Env555 script, it…
-
Analytics: Add Google Analytics gtag.js in wp_head on WordPress Production sites
by
This adds your Google Analytics ID to the head of your public-facing WordPress pages (not your admin pages) and only for users who aren’t logged-in. Replace the XXXXXXXXX with your ID and you’re good to go. By default, it assumes you want to add the script. However, if you’re using my Env555 script, it will…
-
Add ‘Navigation Menus’ to Appearance Menu item back to WordPress admin
by
Add an old school ‘Manage Menus’ link under the Appearance admin menu, so you can easily rename or delete menus (but you can’t really edit them otherwise). Before ➡️ After
-
Force select2 inputs to auto-focus when clicked
by
I have a lot of admin pages where an input (often inside a custom field metabox) is using a select2 dropdown. On some pages, I’ll notice that when I click on the input, it doesn’t automatically focus the text input so that I can start typing, which is usually what I want. So this adds…
-
Add back button to admin headings on WordPress Admin pages
by
Sometimes I’m on an admin screen and I just wanna go back to the parent screen. For example, I’m editing a single post and I wanna go back to the All Posts screen. In that example, it’s easy. But for others, I don’t like futzing around to find the correct menu item. So this script…
-
Display Post Images & Attachments on Edit Screen
by
When I’m editing a post with several images or media files attached, I sometimes like to see all the attachments on the post edit screen rather than visiting the Media Library. This snippet adds a metabox that displays a list of the attachments with links to the Edit Media admin page for each. It works…