Skip to content

Commit

Permalink
Replaced deprecated function
Browse files Browse the repository at this point in the history
  • Loading branch information
kurtpolinar committed Oct 24, 2012
1 parent e22ef58 commit f32668a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions skeleton/admin/options-interface.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ function optionsframework_fields() {
$optionsframework_settings = get_option('optionsframework');

// Get the theme name so we can display it up top
$themename = get_theme_data(STYLESHEETPATH . '/style.css');
$themename = $themename['Name'];
$themename = wp_get_theme();
$themename = $themename->Name;


// Gets the unique option id
if (isset($optionsframework_settings['id'])) {
Expand Down
4 changes: 2 additions & 2 deletions skeleton/options.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
function optionsframework_option_name() {

// This gets the theme name from the stylesheet (lowercase and without spaces)
$themename = get_theme_data(STYLESHEETPATH . '/style.css');
$themename = $themename['Name'];
$themename = wp_get_theme();
$themename = $themename->Name;
$themename = preg_replace("/\W/", "", strtolower($themename) );

$optionsframework_settings = get_option('optionsframework');
Expand Down

0 comments on commit f32668a

Please sign in to comment.