You need to enqueue your stylesheets and script to wp_enqueue_scripts
hook.
In your functions.php try
function enqueue_scripts_cp() {
wp_enqueue_style( 'style', get_stylesheet_uri() );
}
add_action( 'wp_enqueue_scripts', 'enqueue_scripts_cp' );
Related Posts:
- Why I can’t add a CSS style in this WordPress theme?
- Dequeue a style file which is making website load slow!
- Theme Loading Into Dashboard
- Font Awesome 5 Free – far working but fas is not? [closed]
- Having issue with WordPress wp_enqueue_style
- How to add CSS class to custom logo?
- How to add custom css file in theme?
- How important is it to enqueue a theme’s stylesheet?
- Do I actually need to link my theme’s style.css in the theme files
- Enqueue a stylesheet for login page and make it appear in head element
- CSS classes for theme
- Are the WordPress Core CSS styles really all nessesary?
- How to make a theme with more than one CSS file?
- Editing the custom background CSS
- What can I hook into after_setup_theme?
- Adding inline styles from a widget
- CSS in child theme not overriding the parent theme [closed]
- Advantages of using instead of wp_enqueue_style()?
- How to add dynamic inline style?
- Enqueued Stylesheets Effecting Admin Styles
- How to highlight the current page in the nav menu?
- De-registering parent style sheet css recommended?
- Sub folder CSS that’s read by Admin panel
- Where is definied the theme location for the main menu in a WordPress template?
- enqueue_style is not working
- How can I let templates choose which stylesheets are enqueued?
- Stylesheet not linking
- How to edit my theme for full width?
- How to check if a WordPress core block is active in sidebar
- Which html elements should be styled in wordpress theme
- How remove render blocking css from wordpress when you build a theme?
- WordPress Unite Theme: Footer isn’t sticking [closed]
- What is the meaning of WordPress’s recommended css classes and where are they applied?
- How do I use a color from theme options?
- Ideal inline dynamic CSS injection
- Theming Using Bootstrap Glyphicons and WordPress Dashicons
- Some questions about how proper add 2 CSS file in a WordPress theme?
- How can I wrap all blog posts image with
- LESS not working in WordPress [closed]
- A post with a clear:both in its css destroy the theme design, and the sidebar is moved to the bottom
- Why I obtain different visualization when I run the website on my local machine and on remote server?
- Some doubts about WordPress handle the horizontal main menu visualization
- Can’t change theme name
- How to use the _S framework
- Is there a list of default generated Gutenberg block CSS? Unable to align video blocks
- Why nav_menu_css_class doesn’t work with apply_filters?
- How can I fix my theme header for my CSS stylesheet?
- How to generate a rtl.css file for themes?
- Why the slideshow is not shown in my theme?
- adding navigation to genesis themes
- Custom link color or stylesheets
- What is The Best Way to Make Parallax header effect for wordpress theme ?? pure CSS or using JavaScript? [closed]
- Copying the theme style files and images to duplicate the website but with a difference
- Why still output /wp-content/themes/twentynineteen?
- White screen when attaching css to function.php
- Assign custom classes to the divs inside the loop
- Are there any caveats to compiling all of my theme’s SCSS into the style.css file in the theme root?
- SVG in list-style-image breaks when adding fill
- WordPress theme resource won’t load over VPN
- I have WordPress setup on primary domain, how do I set it up on its subdomain using the same database?
- Which cache is kicking
- How to set Post meta-box defaults based on the choices made by user in Customizer?
- Theme Action to hook for one time only function [duplicate]
- theme-independent CSS/JS files
- I can’t add CSS with functions.php
- Alignment Problem [closed]
- How to style bootstrap container in wordpress theme?
- What $handle does WordPress use for a theme’s implicit style.css?
- searchform.php doesn’t work properly
- CSS added through customizer neglects the need of a child theme?
- Issue when posting updates/changes to wordress
- How to override template files in parent theme?
- Customizer: get_preview_url() inside customize_save_after hook
- One Site. One Theme. Multiple Stylesheets without plugins?
- Valid SQL query not returning results
- How to track a users last visited page?
- get_header action not working
- In a Gallery with limited image posts, how do I not limit images on single post?
- Shortcodes do not work in own template
- Adding Bootstrap to WordPress TwentySixteen Theme
- Unable to change the priority with ‘remove_action’ and ‘add_action’ in child theme
- Place title (in correct place) above image with opaque background [closed]
- StoreFront WordPress theme: How can i create a new Home page with Custom design same as template [closed]
- How do I include a partial from a directory below a wordpress theme directory?
- Is there a way to switch to another theme?
- multiple html/css files for wordpress theme?
- New to WordPress – Read the Codex, Other Docs; Still Confused
- CSS preprocessor file messed up after compiled
- How add built-in textarea in theme development?
- Create theme for mobile phones and tablets only?
- Unwanted empty line at the beginning of document
- How to add custom page elements to the WYSIWYG editor?
- Why is my container argument not working for wp_nav_menu() [closed]
- Remove h1 from 2015 theme
- Never actually adding the action? Or do I have to call the action?
- WordPress pulling in random page themes
- best practices for updating wordpress theme
- Customize Option Framework
- How to create a WP theme that use BootStrap? [closed]
- Filter didn’t work on content class (hybrid_post_attributes)