Users with the ability to perform administrative tasks for a site or a network of sites.

learn more… | top users | synonyms (1)

241
votes
108answers
121k views

Best Collection of Code for your functions.php file [closed]

Please vote on the question and any answers you find useful by clicking on the UP arrow on the left hand side of the question or answer. As with many others who are now viewing this post, I have been ...
44
votes
7answers
24k views

Organizing Code in your WordPress Theme's functions.php File?

The more customization I make to WordPress the more I start thinking about if I should be organizing this file or splitting it up. More specifically, if I have a bunch of custom functions which only ...
22
votes
5answers
17k views

Creating a table in the admin-style?

What is the recommended way of creating a page with a table, in the style of the tables showing posts or users in the admin area? I am expanding the Cache Images plugin, and it contains a table with ...
20
votes
1answer
12k views

how to filter post listing (in WP dashboard posts listing) using a custom field (search functionality) ?

despite the fact I googled a lot, I've not found the answer to a very simple question : I have some posts with a custom field (ie supplier_name). I would like to be able to search and filter my posts ...
19
votes
5answers
13k views

What are the standard admin CSS id/class tags?

Is there a list of WordPress CSS id/classes that i can use to build plugin option screens that look and feel more like a normal WordPress option page? i have found some through serendipity but it ...
17
votes
6answers
19k views

Changing the Order of Admin Menu Sections?

I am getting a bit frustrated over here after having spent a few hours trying to accomplish this fairly simple task without any luck. Essentially I have 5 custom post types which I created and all I ...
16
votes
3answers
7k views

Adding an Arbitrary Link to the Admin Menu?

Is there a way to add a arbitrary hyperlink to the WordPress admin menu (I mean the menu on the left when you log into the admin dashboard)? For example, can one add a link to Google? In my ...
15
votes
4answers
11k views

Add a Separator to the Admin Menu?

Does anyone know how to add an admin menu separator? I found this but it did not help. Any ideas?
13
votes
7answers
8k views

Loading External Scripts in Admin but ONLY for a Specific Post Type?

So I continue to run into this issue and I just looking for the best and simplest solution to solve this problem. I have come to make use of custom post types in many different projects and have ...
12
votes
6answers
11k views

How to remove admin menu pages inserted by plugins?

I've got the following code, which cleans up a lot of stuff that is not going to be used within the admin area: add_action( 'admin_menu', 'my_remove_menu_pages' ); function my_remove_menu_pages() { ...
12
votes
1answer
8k views

Customize Edit Post screen for Custom Post Types?

What's the best way to completely customize the Edit Post admin screen for a specific custom post type? I have customized it to an extent already on creation of the custom post type - adding ...
11
votes
1answer
15k views

Add filter menu to admin list of posts (of custom type) to filter posts by custom field values

This answer is very close to what I am looking to do, but instead I would like to specify a specific custom field and display a select menu of its available values. Thanks!
10
votes
1answer
420 views

Changing the “Plugin Activated” Message Default

Whenever an administrator in WordPress activates a plugin, upon the reload of the plugin page, a notice will appear upon successful activation reporting "Plugin Activated". Is there a way to change ...
10
votes
1answer
1k views

WP 3.8 Default Admin Colour For All Users

I am surprised with the new colour scheme for 3.8 and although the classic 3.7 theme has gone, I would like to set the new "Light" colour scheme as the default for all users, but at the same time, ...
10
votes
1answer
3k views

wp_verify_nonce vs check_admin_referer

What is the difference, which one should I use? I know that wp_verify_nonce checks the time limit, and check_admin_referer I think calls wp_verify_nonce as well as checking for an admin url segment, ...
10
votes
1answer
534 views

Find out which moderator approved comment?

Is there any way to find out what moderators have approved a comment, and then display that information on the front-end? e.g. John says: "This is a great article" - Approved by Admin1
10
votes
2answers
3k views

Setting admin edit panels & metaboxes positions and visibility for ALL users and admins

My WP 3.3 setup involves several post types and customized edit panels with Advanced Custom Fields plugin (which creates many metaboxes) and other plugins such as SEO metabox panel, Scribu's ...
9
votes
6answers
4k views

Disable dragging of meta boxes?

Anyone know how to disable this functionality so the meta boxes can't be repositioned?
9
votes
4answers
198 views

This CSS Stuffing Works, But Is This A Good Practice?

I am trying to include a dynamic css in my plugin, I have been searching anywhere but doesn't find any case that is similar to what I do. And what I use to do it is by adding a css file directly into ...
9
votes
4answers
1k views

Is it possible to create a Wordpress tour? V3.3.1

I've recently upgraded to version 3.3.1 and noticed a nice feature that would be great for our non-Wordpress savvy clients - creating a tour of how to use Wordpress. I've used the Yoast SEO plugin ...
9
votes
5answers
9k views

How to use more than 256MB of memory in the admin?

I'm building a site for a photographer who uploads pictures that are normally large for todays digital cameras. Images are quite memory intensive, especially the image operations like creating ...
8
votes
2answers
8k views

Load a script just to custom post type in admin

I have created a custom post type "portfolio" with something like this : $args = array( 'labels' => $labels, 'public' => true, 'publicly_queryable' => true, 'show_ui' => ...
8
votes
1answer
5k views

How to determine whether we are in add New page/post/CPT or in edit page/post/CPT in wordpress admin?

This seems like simple thing but I need way to determine whether the current screen is for Add New or Edit ( a sort of wordpress admin conditional tag). Is there a built in function for this already, ...
8
votes
3answers
5k views

How to remove entire admin menu?

I need to customize the admin panel for my user. So how do I remove the entire admin menu? Not remove the menu item, I mean entirely remove the left vertical menu bar, include the design of the menu ...
8
votes
2answers
372 views

Securing Admin Accounts - Username Discovery

We've had Limit Login Attempts installed for some weeks now, and the number of brute force attempts occurring on wp-admin/wp-login is pretty amazing. At first the attempts were all with the username ...
7
votes
4answers
5k views

Showing User's Post Counts by Custom Post Type in the Admin's User List?

I'm trying to figure out how to hook into the /wp-admin/users.php manage page to create custom columns for showing the number of posts users have for the custom post types on WPHonors.com. I created ...
7
votes
6answers
2k views

What are the best practices for updating?

Don't want to do anything to take down my blog. Here are some upgrade-related questions: How often should Wordpress be updated? What is the best way to do it? How to know if there is a problem with ...
7
votes
3answers
2k views

Set Default Listing “View” in Admin

I'm looking for a way to set the default "View" options under post types in the admin area. For example, by default Posts will default to a "list" view instead of "excerpt" - I'd like to change this ...
7
votes
1answer
2k views

Remove the “View” Link in Post Admin

I have a custom post type that I'm just using just to keep data in but I sometimes share it with others, and I don't want any confusion when the "view" link appears in the admin column. Is there a ...
7
votes
2answers
3k views

How can I speed up my WP admin section?

We have many WP sites with a proxy in between the servers that they sit on and the internet. Some things in WP simply don't work: RSS feeds on dashboard looking up themes looking up plugins core ...
7
votes
3answers
403 views

How can I target WordPress 3.8 new interface MP6 with CSS?

When MP6 was a plugin in WordPress 3.6+ it changes the body class of the admin and added an "admin-mp6" class which helps me to style my plugin accordingly. Now with the latest Alpha of WordPress 3.8 ...
7
votes
2answers
4k views

Any guides on creating custom admin pages?

I basically want to create a table (preferably AJAXified) that lets the user enter a line of information, and be able to add new lines of information, and delete selected ones. I've found this post ...
7
votes
2answers
4k views

Sort admin menu items

On a related note to "Changing the Order of Admin Menu Sections?", I'm looking for a way to alphabetically sort the entries in each sub-section of WordPress's admin area. Currently, whenever a new ...
7
votes
1answer
245 views

Notification that the admin is online

How can I say to all visitors that the admin is online. I mean if the admin is online all the visitors, registered and none registered, will see this words "hello the admin is online...talk with ...
7
votes
6answers
7k views

Admin Ajax is returning 0

I am relatively new to jQuery and AJAX in particular. I have a small issue with the return value always being 0, though I think this is actually the success message and it's not returning anything. I ...
7
votes
3answers
1k views

Editor Styles and Typekit

My website uses typekit to grab custom fonts, which works on the frontend. I'd like to put this in my editor styles in the backend. However, I don't know how I would do this. Typekit uses a js embed ...
7
votes
1answer
193 views

How do I optimize a custom post type admin page with 25,000 posts?

I'm getting the occasional excessive resource limit error to due to loading so many posts at once. We had set the PHP limit to 128 but just loading the list of posts for a couple of the post types is ...
7
votes
1answer
1k views

How-to make the admin area mobile friendly [closed]

Currently the admin-UI is a no-go for mobile browsers. Therefore I'm searching for a plugin that makes the back-end/admin-UI accessible and a little more friendly for mobile devices. Features, the ...
6
votes
2answers
7k views

How do I load a CSS style into WordPress admin area only?

I'm trying to load a CSS file for my WordPress post area, but having no luck. I have read over the wp_enqueue_style function and came up with the code below, but it doesn't load up. Is there a tag or ...
6
votes
3answers
3k views

Change admin bar to default:off

While I quite like the admin bar I actually want it to be OFF by default instead of ON ( I don't want to disable it altogether because I want users to be able to turn it on if they want - but but I ...
6
votes
1answer
1k views

Disable Media Uploads to non Admin Users

I am working on a clients site, one of the features they want is for his Editors or Authors to only be able to select existing images to insert into Posts from the Media Library. So looking at the ...
6
votes
2answers
5k views

3.3: How do you hide the new dashboard welcome panel?

I have tried various versions of this here: unset($wp_meta_boxes['dashboard']['normal']['high']['dashboard_wp_welcome_panel']); ...
6
votes
5answers
2k views

How can I make an Ajax login form work with FORCE_SSL_ADMIN enabled?

I'm working on a site that requires an https secured admin area and a secure front-end area as well where private information will be shown. My preference for user login is an Ajax-enabled widget that ...
6
votes
1answer
1k views

Change admin language based on user (in single-site)

I'm trying to make a small plugin to install in some sites of a german client. I can make my way around WordPress in german, but would be easier if it was in english. There's a plugin that manages ...
6
votes
2answers
3k views

admin page redirect

Is it possible to redirect users to an admin page if they access another admin page? For example if they a user ever hits "all pages" /wp-admin/edit.php?post_type=page they would get redirected to ...
6
votes
5answers
3k views

How to hide admin account in BuddyPress? (for security reasons)

I have been working with WordPress for the past 3-4 years, but I am new to BuddyPress. I would like to hide the admin account completely from BuddyPress for security reasons. For example with a ...
6
votes
1answer
2k views

Settings API - easiest way of validating checkboxes?

I'm using Settings API and I can't get checkboxes to work, if they're set to "false" they're not even being $_POST and that's the point. Stephen Harris & Chip Bennett explained it, but I believe ...
6
votes
2answers
664 views

Merge two custom post types into one admin page?

I am building a site with 4 custom post types. To make things easier for our client/admin, I'm wondering if there is a way to merge those custom post types into one list in the backend? Like if you ...
6
votes
2answers
444 views

sort child pages on admin

I have a hierarchical CPT with the following structure: - parent item 1 - child item 1 - child item 2 - child item 3 - child item 4 - child item 5 - parent item 2 - child item 1 ...
5
votes
2answers
163 views

What is the best way to customise admin files so they survive future upgrades?

I have a site with some custom post types, one of which doesn't have a title. When viewed in the admin section, the posts are listed like so Which is less than ideal, for obvious reasons. I have ...