Getting Theme information from the style.css file in Wordpress

php, themes, wordpress

Solution

`get_theme_data`

Problem

With a Wordpress theme, it is necessary to add information to the top of the style.css file: e.g; for the default theme there is this: ``` /* Theme Name: WordPress Default Theme URI: http://wordpress.org/ Description: The default WordPress theme based on the famous <a href="http://binarybonsai.com/kubrick/">Kubrick</a>. Version: 1.6 Author: Michael Heilemann Author URI: http://binarybonsai.com/ Tags: blue, custom header, fixed width, two columns, widgets */ ``` Are there any wordpress functions to get this information programatically?

Original source