Tag Archive: admin

Admin-triggered e-mail

Here’s something that touches on lots of topics. A ‘send e-mail’ button within an admin panel, that opens up a ThickBox window with a standalone form and wp_editor.

The metabox

This requires two functions: one hooked into ‘add_meta_boxes’ which calls the second, the metabox output function:

Most of the second function builds the URL for the button’s href attribute. It points to a ... 

Read article

Disabling autosave

You may already know, custom post types are the real workhorses of most customized WordPress themes. But often, they’re not meant to be read by the public; they’re functional things like ‘albums’ or ‘reservations’ or ‘index cards.’ By default, WordPress tries to create auto-drafts of any post type when an author is adding / editing through the admin panel, and ... 

Read article

Draft status highlighting

A client wanted to display items with ‘Draft’ status differently (gray color) in the admin list pages. Some might argue I’m a sloppy coder for using inline CSS, but there’s something I like about targeted post types, particularly in admin pages. Anyway, here’s a good example of using the ‘admin_footer’ action and certain global variables, very useful.

This snippet (stick it ... 

Read article