From 4147a731ceb895dc48a3988d10761b9e1210663b Mon Sep 17 00:00:00 2001 From: John Bintz Date: Tue, 5 Jan 2010 21:13:46 -0500 Subject: [PATCH] change name of variable to avoid conflict with global, fixes WP#11712 --- functions.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/functions.php b/functions.php index 1f496a6..afb6950 100644 --- a/functions.php +++ b/functions.php @@ -284,9 +284,9 @@ if ($comicpress_options['remove_wptexturize']) { // WIDGETS WP 2.8 compatible ONLY, no backwards compatibility here. $dirs_to_search = array_unique(array(get_template_directory(), get_stylesheet_directory())); $__comicpress_handlable_classes = array(); -foreach ($dirs_to_search as $dir) { +foreach ($dirs_to_search as $__dir) { foreach (array('classes' => 'inc', 'widgets' => 'php', 'functions' => 'php') as $folder => $extension) { - foreach (glob($dir . "/${folder}/*.${extension}") as $__file) { + foreach (glob($__dir . "/${folder}/*.${extension}") as $__file) { require_once($__file); $__class_name = preg_replace('#\..*$#', '', basename($__file)); if (class_exists($__class_name)) { @@ -916,3 +916,4 @@ function random_post() { if ( isset( $_GET['randompost'] ) ) add_action( 'template_redirect', 'random_post' ); +