Questions tagged [admin-css]

WordPress' flexible nature allows for almost every part of it to be easily changed. Creating a custom WordPress Admin Panel Theme is no different. There are essentially two ways of making a WordPress Admin theme: with a Plugin or by simply changing the CSS.

Filter by
Sorted by
Tagged with
7 votes
3 answers
8k views

How to add custom css to login and admin?

I have custom CSS for the login and admin pages. Is it OK to add it as I've done below, or is there a better alternative? function custom_admin_css() { wp_enqueue_style( 'custom_admin_css', ...
glvr's user avatar
  • 861
0 votes
1 answer
4k views

Apply custom css for user role

How can I apply custom CSS for user role, both for dashboard and frontend? For dashboard I set: if( current_user_can('seller', 'partner')) { function admin_style() { wp_enqueue_style('admin-...
Rafal's user avatar
  • 312
0 votes
1 answer
143 views

How to reference an existing css content-based icon, within my admin menu hook

Within WordPress 4.6.1, I really like the thumbtack icon that is being used in the admin menus. This is the thumbtack icon (generated in CSS) that I am referring to... I'm currently using the ...
klewis's user avatar
  • 845
1 vote
0 answers
842 views

How to enable table overflow scroll? (especially order list table)

Above in image the order list table not able to scroll horizontally and also breaking the words . I want to make scroll . Help me how to do this ?
user2007245's user avatar
0 votes
1 answer
130 views

Distributing Frontend Assets with Plugins

I'd like to distribute some custom style sheets (.css) and javascript files (.js) with my plugin. Is there a right way to do this in Wordpress? I can think of a number of different ways to do this, ...
Alana Storm's user avatar
3 votes
2 answers
2k views

What is better way to use Bootstrap inside admin panel?

I need to use Bootstrap CSS for better UI in wp-admin but if I enqueue the bootstrap.css, it's affecting the admin default UI by changing background colors, etc. How can I use bootstrap.css inside wp-...
Bhavesh Nariya's user avatar
7 votes
2 answers
4k views

Adjust the Device Preview sizes used in the WP 4.5 Customizer

WP 4.5 introduced the Device Preview in the Customizer and it's pretty easy to use. Click one of three icons and see your site at various (predetermined) sizes. The desktop version will always fill ...
jgraup's user avatar
  • 9,699
0 votes
1 answer
177 views

Margin problem on management menu?

I'm developing a Wordpress site (www.costactiva.com). It's a multilingual site with around 15 languages at the end. I found this 'mistake?' in the Menus area: When I have more languages than they fit ...
Sonia's user avatar
  • 3
1 vote
1 answer
393 views

What exact CSS minifier does WP core use?

WordPress core ships css files in both source and minified form. E.g. wp-includes/css/admin-bar.css and wp-includes/css/admin-bar.min.css. Does anyone know exactly what tool they use to do the ...
sootsnoot's user avatar
  • 123
2 votes
3 answers
2k views

How to add background image control to page admin controls?

I understand that each page is assigned its own class such as .page-id-22 & I can use that to assign a background image to it using the stylesheet but I've seen a theme that adds a control to the ...
Jeff W's user avatar
  • 118
0 votes
3 answers
817 views

Custom css author role

I need a code snippet to load css (extra style sheet?) when a author is logged in. This is for a custom dashboard and post "page". The screenshot is what i mean by post page. I want to hide stuf by ...
Arnolddew's user avatar
0 votes
2 answers
56 views

Media Upload not working after hiding some elements from functions.php

I have put the below code in functions.php. (It's used to hide some options from client.) But the problem is, after adding these codes, images are not uploading, can't even even uploaded photos from ...
Gijo Varghese's user avatar
0 votes
0 answers
1k views

wp_is_mobile() inside js

I've stumbled upon a issue that i can't fix. I've implemented a autocollapse menu ..all works fine UNTILL i go to mobile version where the wp core's menu bugs out with my menu js code. Basicly i ...
andreiudeiu's user avatar
1 vote
1 answer
1k views

Can't resize logo in responsive theme?

I've been knocking my head against this one for hours. I haven't dabbled in web development in years, so I'm very rusty. I setup a new website, clearerlines.net, designed a logo for the header, and ...
Truefire's user avatar
0 votes
2 answers
2k views

prevent front end theme from injecting css into wp-admin

I've created a custom child theme of parent theme Cordillera. This is my child theme's header.php (<head>): <!DOCTYPE html> <html <?php language_attributes(); ?>> <head&...
Steve's user avatar
  • 1,677
0 votes
1 answer
74 views

conditionally update css on edit.php

I want to change the background-color of each row in the posts table based on some date checks. The css I need to change is tr#post-nnnn {background-color:$myColor} where nnnn is the post number and $...
WPD_tobe's user avatar
0 votes
0 answers
163 views

Simple CSS admin pagination

First of all thanks for your time :). I have a dropdown menu option for the admin menu..but the pages still render at the menu edge. Any css trick to position pages correctly? Thanks in advance.
andreiudeiu's user avatar
5 votes
2 answers
941 views

Add visit site to your toolbar instead of being in the dropdown

I'm looking for a way to move the "Visit Site" link from drop-down and add it to the main toolbar, just like in the image shown below:
andreiudeiu's user avatar
-1 votes
1 answer
269 views

theme injecting css into wp-admin

Some of the CSS from my theme is being used in wp-admin. For instance "Add New Page" on /wp-admin/post-new.php?post_type=page is coloured blue, which comes from my theme, as stated by Chrome code ...
Steve's user avatar
  • 1,677
1 vote
1 answer
2k views

Adding HTML tags or css classes to admin columns

Is it possible to add a custom class to the links in admin columns? I'm trying to replicate the labels below. I'm using WP 4.1 and my CPT is using 'show_admin_column' => true in ...
Justice Is Cheap's user avatar
1 vote
1 answer
254 views

How To Differentiate Drafted product and Publish Product through Color?

I want to set a different color border for product drafts and published products in my WordPress backend page. If there is a drafted product in my WordPress product listing page then it should have a ...
Yogesh Chalodiya's user avatar
16 votes
9 answers
79k views

No CSS being loaded on backend

I have a WordPress installation on AWS and I was facing an issue that authors are not able to submit content like media in one go and a time-out error occurs. After refreshing the page 5-6 times ...
Neal's user avatar
  • 261
2 votes
2 answers
1k views

Deregister CSS style link 'open-sans-css'

When user is logged in WP add in its footer this CSS: <link rel='stylesheet' id='open-sans-css' href='//fonts.googleapis.com/css?family=Open+Sans....' type='text/css' media='all' /> That ...
Advanced SEO's user avatar
0 votes
1 answer
536 views

Simple/basic use of get_current_screen

I would like to load a stylesheet on only 3 admin pages: post.php?post=7&action=edit post.php?post=10&action=edit post.php?post=18&action=edit I was trying with admin_enqueue_script but ...
codeview's user avatar
  • 455
0 votes
1 answer
158 views

Is it possible to be more page/post specific with admin_enqueue_script?

I am using this code to load a stylesheet in the admin, but only on post.php related pages: function my_enqueue_for_post_pages_only($hook) { if( 'post.php' != $hook ) return; ...
codeview's user avatar
  • 455
3 votes
6 answers
4k views

Hide Front-End Admin Bar Including 32 px Spacing

I have a custom template and I inserted the following snippet to get rid of the admin bar for the page: function hide_admin_bar(){ return false; } add_filter( 'show_admin_bar', 'hide_admin_bar' ); ...
Adam's user avatar
  • 349
0 votes
2 answers
204 views

Adding custom css to a theme depending on whether the admin user is logged in or not

Is it possible to add custom css to a stylesheet in a theme depending on whether the user is logged in or not? When I log in, the theme navigation and when viewing the main site bar is hidden behind ...
Jonathan Beech's user avatar
7 votes
3 answers
18k views

How do i use fontawesome icons in TinyMce editor?

I'm trying to add a youtube button in TinyMce editor. here is a recent-posts.js file which is in the js folder of the theme directory. (function() { tinymce.create('tinymce.plugins.buttons', { ...
user1906399's user avatar
1 vote
3 answers
3k views

Admin WP List Table Columns Missing

The wordpress admin tables used on pages like www.example.com/wp-admin/edit.php uses a class class-wp-list-table.php In this class there are two functions that hide specific table columns with {...
Bryan Willis's user avatar
  • 4,379
1 vote
1 answer
2k views

Set admin body to ltr on a rtl installation

I am using a rtl WordPress installation (Hebrew language) and have the following problem: On the admin interface, most of the plugins I install do not have a rtl stylesheet and therefore the plugin ...
Yair Levy's user avatar
  • 111
-1 votes
2 answers
84 views

Target "admins" with different styles on the front end [closed]

I'll first explain what i'm trying to do. I am building an intranet for a client. They do not want employees to be able to edit their profiles or upload avatars, just "admins" should be able to do ...
Zach Russell's user avatar
  • 1,043
0 votes
1 answer
2k views

Adding CSS to admin TinyMCE editor for custom button

I have created a plugin that adds a new button to the TinyMCE editor in the admin edit pages/posts area. I am trying to apply a font icon to it as per the the other buttons in Wordpress 3.8. I have ...
McShaman's user avatar
  • 179
4 votes
3 answers
17k views

How to hide menu on WordPress admin

I want to hide some menus on admin panel: Appearance, Plugins, and Tools. How to hide it without plugin? And how can I un-hide them later easily?
Lena Queen's user avatar
2 votes
1 answer
3k views

Dashicons and Pseudo :before

I am generating a custom post type that uses the dashicons and allows users to select one to associate with the post. The idea being the user can select an icon from a drop down list and it is ...
iamdannywilson's user avatar
0 votes
2 answers
1k views

Restrict CSS on one page

I have my site: http://theapkstore.com . On the homepage I've added a slider. And reduced the top margin of widget which says "Welcome to my site". The homepage looks fine but then when I open any one ...
Mohammad Areeb Siddiqui's user avatar
0 votes
0 answers
136 views

Change Login CSS - Include instead of echo

I'm trying to figure out how to include a stylesheet instead of echo'ing <style> tags. I'm currently using the following function: // Custom Login Styles function login_styles() { echo '&...
Austin Biggs's user avatar

1
2