رفتن به مطلب

اجرا نشدن child theme در پوسته


پست های پیشنهاد شده

باسلام ، 

من قالبم ی child theme داره ، هرکاری میکنم مینویسه پوسته مادر پیدا نشد ... فکر کنم توو فانکشن قالب کدی قرار داره child theme رو بسته 

توو خطوط 17  فانکشن بصورت کامنت گذاشتن not child theme 

فانکشن :

 

<?php

// ensure EXT is defined
if ( ! defined('EXT')) {
	define('EXT', '.php');
}

#
# See: wpgrade-config.php -> include-paths for additional theme specific
# function and class includes
#

// Theme specific settings
// -----------------------

// add theme support for post formats
// child themes note: use the after_setup_theme hook with a callback
$formats = array('image', 'video', 'link', 'gallery', 'audio');
add_theme_support('post-formats', $formats);

// Initialize system core
// ----------------------

require_once 'wpgrade-core/bootstrap'.EXT;

#
# Please perform any initialization via options in wpgrade-config and
# calls in wpgrade-core/bootstrap. Required for testing.
#

/**
 * http://codex.wordpress.org/Content_Width
 */
if ( ! isset($content_width)) {
	$content_width = 960;
}

function post_format_icon($class_name = '') {
	$post_format = get_post_format();

	if ($post_format):
		$icon_class = "";
		switch ($post_format) {
			case "video":
				$icon_class = "icon-play";
				break;
			case "audio":
				$icon_class = "icon-music";
				break;
			case "image":
			case "gallery":
				$icon_class = "icon-camera";
				break;
			case "quote":
				$icon_class = "icon-quotes";
				break;
			case "link":
				$icon_class = "icon-link";
				break;
			default:
				break;
		}
		 ?>
		<div class="post-format-icon <?php echo $class_name; ?> post-format-icon__background"></div>
		<div class="post-format-icon <?php echo $class_name; ?> post-format-icon__border"></div><?php  ?>
		<div class="post-format-icon <?php echo $class_name; ?> post-format-icon__icon">
			<i class="<?php echo $icon_class; ?>"></i>
		</div>
	<?php
	endif;
}

 

لینک به ارسال

درود ، 

دقت کنید دوست عزیز باید نام بچه پوسته و پوسته مادر در داخل فایل css و همچنین نام پوشه بچه پوسته و پوسته مادر ارث بری باشد و هماهنگ باشند.

mytheme و mytheme-child - پس یادآور میشوم که نام پوشه ها ، فایل استایل و فایل فانکشن باید هماهنگ باشند.

لینک به ارسال

لطفا برای ارسال دیدگاه وارد شوید

شما بعد از اینکه وارد حساب کاربری خود شدید می توانید دیدگاهی ارسال کنید



ورود به حساب کاربری
×
×
  • اضافه کردن...