The style.css template file is a file that writes only the CSS code required for every WordPress theme. Controls the presentation (visual design and layout) of the site pages.
the site style.css
In order for WordPress to recognize the set of theme template files as a valid theme, the style.css file must be located in the root directory of your theme , not a subdirectory.
For a more detailed explanation of how to embed a style.css file in a theme , see Understanding CSS and JS Files in a WordPress Theme – Part 3.
WordPress uses the style.css header section to display information about the theme in the WordPress Appearance panel.
Example # Example
Below is an example of the starter portion of the style.css file . We write the following comment:
/* Theme Name: newtheme Theme URI: https://studyshoot.com/ Author: Ahmad Al Hariri Author URI: https://wpmrj3.com/ Description: newtheme is an Educational Website which contain alot of Contents, Students and young People would be interested in our Topics which we publish. You can find here Scholarships, Universities Information and also Medical Information beside the Web Magazine and more. Version: 3.7.8 Text Domain: newtheme Tags: one-column, two-columns, left-sidebar, flexible-header, accessibility-ready, custom-header, custom-menu, custom-logo, editor-style, featured-images, footer-widgets, post-formats, rtl-language-support, sticky-post, theme-options, threaded-comments, We make it to let users have easy access to the newtheme Website. */
Clarification of the previous nomenclature # Interpretations
Items marked with an (*) are required for the theme in the WordPress theme repository.
- Theme Name (*): The name of the theme.
- Theme URI: The URL of a public webpage where users can find more information about the theme.
- Author (*): The name of the person or organization that developed the theme.
- Author URI: The URL of the authoring individual or organization.
- Description (*): Brief description of the theme.
- Version (*): Theme version, written in XX or XXX format.
- Requires at least (*): Oldest major version of WordPress will run the theme, written in XX format
- Tested up to (*): The last major version of WordPress that the theme was tested on, ie 5.4. Just type the number in XX . format
- Requires PHP (*): Oldest supported PHP version, in XX format, number only
- License (*): Theme license.
- License URI (*): The URL for the theme’s license.
- Text Domain (*): The string used for the theme translation domain.
- Tags: words or phrases that allow users to find the theme using the tag
- Domain Path: Used so that the theme knows where to find translation when the theme is disabled.
After the previous line section, style.css can contain anything a regular CSS file contains.