You can simply add those CSS to admin HEAD section, it’s fast and easy solution.
function jrl_styles() {
?><style type="text/css">
#jrl-wrap {
width: 700px;
padding: 3em;
/* ... */
}
</style><?php
}
add_action('admin_head', 'jrl_styles');
Or you can enque your CSS file like this:
function load_custom_wp_admin_style() {
wp_register_style( 'custom_wp_admin_css', get_stylesheet_directory_uri() . '/functions/site-options.css', false, '1.0.0' );
wp_enqueue_style( 'custom_wp_admin_css' );
}
add_action( 'admin_enqueue_scripts', 'load_custom_wp_admin_style' );
Both options will add those CSS code (or file) to every admin page, so have your CSS definiton prefixed to aviod some collisions with WordPress CSS. Your CSS code looks OK.
Edit: Changed get_template_directory_uri() (always returns parent theme folder) to get_stylesheet_directory_uri() (returns child-theme folder).
Related Posts:
- Is it possible to disable a function of a parent theme?
- How to override an unpluggable parent theme function?
- How do I remove a require_once admin panel from the parent theme from the child theme functions.php?
- Copyright info change in Theme Child PHP
- Add footer.php to WordPress child theme
- Best way of adding CSS which can be manipulated by the user via theme option panels?
- Setting up the child theme so as to enable right-to-left WordPress?
- How to override a non pluggable and non hookable function in a WordPress parent theme?
- Understanding WordPress child theme custom JS loading
- Understanding child theme functions.php
- Overriding a theme redux file in child theme
- Want to create Child theme, but already edited Parent theme css files and some php files
- Using PHP to toggle stylesheet and header image, set in cookie
- Adding tawk.to code just before body tag on functions.php file
- Shortcode content output but not in correct place
- WordPress child theme fails to override parent navigation menu in /inc/structure/header.php
- Hide Hamburger Menu On Specific Page (Front Page/Home Page)
- Parent theme CSS overriding child CSS rules
- Css loads very slow [closed]
- two columns of posts on homepage, one of them “favorites”
- responsive.css in the WordPress should be prioritized
- Custom Background by Page IDs
- Copyright info change – Corporate Plus Theme PHP [closed]
- height should be set to auto to avoid pixelation in the post thumbnail function
- How to make container class in PHP
- Creating a mobile site by adding a new class to the body tag from functions.php
- How do I check or test a WordPress Auto Year Change Script?
- How to have different site identity logos on each page on Astra Theme [closed]
- CSS change in woo commerce Place Order Text [closed]
- Problem with adding custom CSS class to image in ACF Photo Gallery plugin [closed]
- Removing “Powered by” footer using child theme PHP [closed]
- Overide Variable in Child Theme
- child parent styles enqueue order
- How to style injected code in header section?
- Child Theme’s Read More Text
- Need advice on theme customizer and child themes
- How to edit background color of only one sidebar?
- Inline CSS header style priority function.php Child (no enqueing I think)
- how to changes mobile menu toggle breakpoint in WordPress
- Why would the child theme load in the Customize preview, but not on the site itself?
- PHP function for horizontal Woocommerce thumbnails and badges
- Proper way to remove html code on child theme
- remove_action from parent theme using child theme functions.php
- File from parent theme imported to child theme doesn’t work – any ideas?
- Problem with displaying CSS Stylesheets – Am I adding them correctly in my wordpress child theme?
- How to change this ajax function to submit to the default wordpress content area instead of the custom field ‘seller notes’?
- Child theme overirde template-tags in a theme built on underscores in inc/template-tags
- PHP “warning include_once(): Failed to open stream” Simple HTML DOM in WordPress Child Theme
- I got big white screen when i attach main style sheet of Html in functions.php
- How to locate parent theme functions and add functions to my wordpress child theme?
- How to let mobile navigation menu close when link is clicked?
- how to add functions to my function.php using a child theme?
- Site title not showing. Please help me
- PHP/CSS: Shortcode won’t display correctly, and only displays in the head (before content)
- Add class for the_post_thumbnail_caption()
- Displaying POST content with HTML tags and all
- Highlight Single Page Ancestor
- Where to find the html for WordPress site? [closed]
- How to remove image on single product and get product to span page?
- Removing get_template_part in child theme
- Modify arguments for parent theme’s `wp_register_style` via child theme
- Styling admin page rows in order of importance (checkboxes)
- How to have Function of a plugin using global vars into a shortcode?
- Child theme not working properly
- Cant get theme to change footer color through theme customizer
- How to add margin underneath woocommerce total price amount -> productpages
- How do I get Roboto Google Font to display normal font-style? [closed]
- Integrating CSS Into a WP Function Call [closed]
- Load slideshow.css file only if Slideshow is checked / on
- Child-theme suddenly stopped working [closed]
- Sorting Problem
- How do I make a shortcode to display Dokan seller badge list?
- Live Preview while customizing is not showing the updates while editing in WordPress
- How can we upload custom page files?
- Calling a PHP function from a menu item
- Hide or Show Read More Button by Content Area
- Override get_template_directory() in child theme?
- Build a content and excerpt grid loop with paging and options for # of posts
- How to get the registered sidebar’s name by its id?
- Show post in slider
- Where to edit the template that is generating the code for dynamic_sidebar left-sidebar in the Understrap theme? [closed]
- Retrieve $_POST data submitted from external URL in WordPress(NOT API)
- Illegal string offset in PHP function
- Displaying text if post was within 5 hours
- Change “No Comments” link to “My String” on Blog Post (Find Snippet in Code or use CSS, PHP Solution) [closed]
- Adding a tag_ID column into Categories inside the admin dashboard?
- My website is not showing Footer section
- Dividing the loop to style post differently
- How to Display a List of Child Pages For a Parent Page in WordPress
- How to add PHP pagination to wordpress
- Help me I cannot link my font-awesome to my WordPress Theme. I have my font-awesome folder already in my project
- Google CSE Malfunctions via Chrome/Safari on Mobile When Clicking on Either Search Icon/Menu Icon. How to Make Google CSE Default Theme Search
- Can an AJAX callback function access a PHP variable which was defined during initial page load?
- How fix error in the WordPress loop?
- Use WP_Query Data In Cookie
- Extend the WP_Customize_Image_Control class to change its non-frame $button_labels
- Pagination not displaying
- Setting WooCommerce currency programmatically
- Masking external links with internal link for member-only
- add_rewrite_rule image from /images/site2/favicon.ico to /favico.ico