From 5018dfe8258be944e3cabb1bfc7a5cb51439a8f2 Mon Sep 17 00:00:00 2001 From: "Philip M. Hofer (Frumph)" Date: Fri, 6 Nov 2009 00:37:44 -0800 Subject: [PATCH] functions.php works now in child themes instead of using childfunctions.php as a partial. Signed-off-by: Philip M. Hofer (Frumph) --- comicpress-options.php | 10 +++++----- functions.php | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/comicpress-options.php b/comicpress-options.php index da16d4c..45c2279 100644 --- a/comicpress-options.php +++ b/comicpress-options.php @@ -1,8 +1,8 @@

@@ -56,13 +55,14 @@ function comicpress_admin() { } // set default options + foreach ($options as $default) { if(get_option($default['id'])=="") { update_option($default['id'],$default['default']); } } - include(get_template_directory() . '/comicpress-config.php'); + @require(get_template_directory() . '/comicpress-config.php'); ?>
@@ -112,6 +112,6 @@ function comicpress_admin() { \ No newline at end of file diff --git a/functions.php b/functions.php index 75b32e5..7fb6fb8 100644 --- a/functions.php +++ b/functions.php @@ -9,7 +9,7 @@ function init_language(){ define('THEME_TEXTDOMAIN','comicpress'); define('THEME_LANGS_FOLDER','/lang'); } else { - load_theme_textdomain( 'comicpress', get_template_directory_uri() . '/lang' ); + load_theme_textdomain( 'comicpress', get_template_directory() . '/lang' ); } } add_action ('init', 'init_language'); @@ -852,7 +852,7 @@ function cp_copyright() { function comicpress_check_child_file($filename = '') { if (empty($filename)) return false; if (file_exists(get_stylesheet_directory() .'/'. $filename . '.php')) { - @include(get_stylesheet_directory() .'/'. $filename . '.php'); + @require_once(get_stylesheet_directory() .'/'. $filename . '.php'); return true; } return false;