رفتن به مطلب

مشکل در هدر


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

سلام

بالای سایتم یه لوگو کوچیک بود

که من به یه هدر تفییر دادم و جاش گذاشتم

ولی الان اینطوری شده:

http://bmtj.ir

چیکار کنم اندازش درست شه ؟

لینک به ارسال

سایز هدر رو درست کردم و اندازش هم درسته

ولی جای لوگوی قبلی که گذاشتم اینطوری شد

کدی چیزی نداره؟

لینک به ارسال

شما این رو به کلاس #header .logo توی استایل قالبت اضافه کن :


width:auto;

ویرایش شده توسط Mr.javad
لینک به ارسال

کد به صورت زیر قرار بدید


<div class="wrapper">
<img src="http://bmtj.ir/wp-content/themes/argentum/images/logos/argentum.png" alt="برج تجاری جیرفت"><!--/.logo-->

لینک به ارسال

index.php


<?php get_header(); ?>
<?php global $woo_options; ?>
<div class="row homepage visible">
<!-- Header widget -->

<section class="header-widget">
<?php if ( function_exists('dynamic_sidebar') ) dynamic_sidebar( 'header-widget' ); ?>
</section><!--/.header-widget-->
<section id="content">
<?php if ( is_woocommerce_activated() ) { ?>

<!-- The first featured product -->

<div class="featured-1 sixcol">

<?php
$args = array( 'post_type' => 'product', 'posts_per_page' => 1, 'meta_query' => array( array('key' => '_visibility','value' => array('catalog', 'visible'),'compare' => 'IN'),array('key' => '_featured','value' => 'yes')) );
$loop = new WP_Query( $args );
if ( function_exists( 'get_product' ) ) {
$_product = get_product( $loop->post->ID );
} else {
$_product = new WC_Product( $loop->post->ID );
}
while ( $loop->have_posts() ) : $loop->the_post(); $_product; ?>

<?php woocommerce_show_product_sale_flash( $post, $_product ); ?>

<a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>">
<?php if (has_post_thumbnail( $loop->post->ID )) echo get_the_post_thumbnail($loop->post->ID, 'shop_single'); else echo '<img src="'.woocommerce_placeholder_img_src().'" alt="Placeholder" width="'.$woocommerce->get_image_size('shop_single_image_width').'px" height="'.$woocommerce->get_image_size('shop_single_image_height').'px" />'; ?>
</a>

<div class="meta">

<h2><span><?php _e('Featured Product', 'woothemes'); ?></span> <a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>"><?php the_title(); ?></a></h2>
<span class="price"><?php echo $product->get_price_html(); ?></span>
<?php the_excerpt(); ?>
<?php // woocommerce_template_loop_add_to_cart( $loop->post, $_product ); ?>

</div><!--/.meta-->

<?php endwhile; ?>

</div><!--/.featured-1-->

<!-- 4 recent products -->

<div class="recent-1 sixcol last">

<ul class="recent products">

<?php
$args = array( 'post_type' => 'product', 'posts_per_page' => 4, 'meta_query' => array( array('key' => '_visibility','value' => array('catalog', 'visible'),'compare' => 'IN'),array('key' => '_featured','value' => 'no')) );
$first_or_last = 'first';
$loop = new WP_Query( $args );
while ( $loop->have_posts() ) : $loop->the_post(); $_product; ?>

<li class="product sixcol <?php echo $first_or_last; $first_or_last = ('first'==$first_or_last) ? 'last' : 'first'; ?>">

<?php woocommerce_show_product_sale_flash( $post, $_product ); ?>

<a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>">
<?php if (has_post_thumbnail( $loop->post->ID )) echo get_the_post_thumbnail($loop->post->ID, 'shop_catalog'); else echo '<img src="'.woocommerce_placeholder_img_src().'" alt="Placeholder" width="'.$woocommerce->get_image_size('shop_catalog_image_width').'px" height="'.$woocommerce->get_image_size('shop_catalog_image_height').'px" />'; ?>
</a>

<div class="meta">

<h3><a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>"><?php the_title(); ?></a></h3>
<span class="price"><?php echo $product->get_price_html(); ?></span>
<?php // woocommerce_template_loop_add_to_cart( $loop->post, $_product ); ?>

</div><!--/.meta-->

</li>
<?php endwhile; ?>

</ul><!--/ul.recent-->

<div class="clear"></div>

<!-- Display the homepage widget area -->

<?php if ( function_exists('dynamic_sidebar') ) dynamic_sidebar( 'homepage-content' ); ?>

</div><!--/.recent-1-->

<div class="clear"></div>

<!-- 4 more recent products -->

<div class="recent-2 sixcol">

<ul class="recent products">

<?php
$args = array( 'post_type' => 'product', 'posts_per_page' => 4, 'offset' => 4, 'meta_query' => array( array('key' => '_visibility','value' => array('catalog', 'visible'),'compare' => 'IN'),array('key' => '_featured','value' => 'no')) );
$first_or_last = 'first';
$loop = new WP_Query( $args );
while ( $loop->have_posts() ) : $loop->the_post(); $_product; ?>

<li class="product sixcol <?php echo $first_or_last; $first_or_last = ('first'==$first_or_last) ? 'last' : 'first'; ?>">

<?php woocommerce_show_product_sale_flash( $post, $_product ); ?>

<a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>">
<?php if (has_post_thumbnail( $loop->post->ID )) echo get_the_post_thumbnail($loop->post->ID, 'shop_catalog'); else echo '<img src="'.woocommerce_placeholder_img_src().'" alt="Placeholder" width="'.$woocommerce->get_image_size('shop_catalog_image_width').'px" height="'.$woocommerce->get_image_size('shop_catalog_image_height').'px" />'; ?>
</a>

<div class="meta">

<h3><a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>"><?php the_title(); ?></a></h3>
<span class="price"><?php echo $product->get_price_html(); ?></span>
<?php // woocommerce_template_loop_add_to_cart( $loop->post, $_product ); ?>

</div><!--/.meta-->

</li>
<?php endwhile; ?>

</ul><!--/ul.recent-->
<!-- Display the latest post -->

<?php if ( $woo_options[ 'woo_homepage_content' ] == "true" ) { ?>

<?php query_posts('posts_per_page=1'); ?>

<?php while (have_posts()) : the_post(); ?>

<article <?php post_class(); ?>>

<h2 class="title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'woothemes' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2>

<aside class="threecol meta">

<ul>
<li class="date"><?php the_time('j F Y', '<time>', '</time>'); ?></li>
<li class="author"><?php the_author_posts_link(); ?></li>
<li class="category"><?php the_category(', '); ?></li>
<!--<li class="tags"><?php // the_tags('Tagged: ',', ',''); ?></li>-->
<li class="comments"><?php comments_popup_link(__( '0 Comments', 'woothemes' ), __( '1 Comment', 'woothemes' ), __( '% Comments', 'woothemes' )); ?></a></li>
<?php the_tags( '<li class="tags">', ', ', '</li>' ); ?></li>
</ul>

</aside><!--/.meta-->

<section class="article-content ninecol last">

<?php the_excerpt(); ?>

</section><!--/.article-content-->

</article><!--/.post-->

<?php endwhile;?>

<?php } else { ?>

<?php } ?>
</div><!--/.recent-2-->

<!-- 2nd featured product -->

<div class="featured-2 sixcol last">

<?php
$args = array( 'post_type' => 'product', 'posts_per_page' => 1, 'offset' => 1, 'meta_query' => array( array('key' => '_visibility','value' => array('catalog', 'visible'),'compare' => 'IN'),array('key' => '_featured','value' => 'yes')) );
$loop = new WP_Query( $args );
while ( $loop->have_posts() ) : $loop->the_post(); $_product; ?>

<?php woocommerce_show_product_sale_flash( $post, $_product ); ?>

<a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>">
<?php if (has_post_thumbnail( $loop->post->ID )) echo get_the_post_thumbnail($loop->post->ID, 'shop_single'); else echo '<img src="'.woocommerce_placeholder_img_src().'" alt="Placeholder" width="'.$woocommerce->get_image_size('shop_single_image_width').'px" height="'.$woocommerce->get_image_size('shop_single_image_height').'px" />'; ?>
</a>

<div class="meta">

<h2><span><?php _e('Featured Product', 'woothemes'); ?></span> <a href="<?php echo get_permalink( $loop->post->ID ) ?>" title="<?php // echo esc_attr($loop->post->post_title ? $loop->post->post_title : $loop->post->ID); ?>"><?php the_title(); ?></a></h2>
<span class="price"><?php echo $product->get_price_html(); ?></span>
<?php the_excerpt(); ?>
<?php // woocommerce_template_loop_add_to_cart( $loop->post, $_product ); ?>

</div><!--/.meta-->

<?php endwhile; ?>

</div><!--/.featured-1-->
<?php } // endif is_woocommerce_activated() ?>

</section>

</div>
<?php get_footer(); ?>

header.php


<?php
/**
* Header Template
*
* Here we setup all logic and XHTML that is required for the header section of all screens.
*
*/
global $woo_options;
global $woocommerce;
$http_or_https = (is_ssl()) ? 'https:' : 'http:';
?><!DOCTYPE html>
<html lang="fa-IR" class="no-js">
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>" />
<!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame -->
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title><?php woo_title(); ?></title>
<?php woo_meta(); ?>
<!-- Mobile viewport scale | Disable user zooming as the layout is optimised -->
<meta content="initial-scale=1.0; maximum-scale=1.0; user-scalable=no" name="viewport"/>
<!-- Display an Apple Touch icon (if present) and load securely if SSL is enabled -->
<?php if ( file_exists(TEMPLATEPATH .'/apple-touch-icon.png') ) : ?>
<link rel="apple-touch-icon" href="<?php echo get_template_directory_uri(); ?>/apple-touch-icon.png">
<?php endif; ?>
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
<!-- CSS -->
<!-- First load the standard stylesheet. Contains theme information only -->
<link rel="stylesheet" href="<?php echo get_stylesheet_directory_uri(); ?>/style.css">
<!-- /CSS -->
<?php wp_head(); ?>
<?php woo_head(); ?>
</head>
<body <?php body_class(); ?>>
<?php woo_top(); ?>
<!-- Here's the actual header markup -->

<header id="header" class="row visible" role="banner">

<section class="top wrapper">

<!-- Customer navigation -->

<nav role="customer-navigation">
<?php if ( function_exists( 'has_nav_menu') && has_nav_menu( 'top-menu' ) ) { ?>
<?php wp_nav_menu( array( 'depth' => 6, 'sort_column' => 'menu_order', 'container' => 'ul', 'menu_id' => 'top-nav', 'menu_class' => 'nav', 'theme_location' => 'top-menu' ) ); ?>

<?php } ?>
</nav>

<div class="clear"></div>

</section><!--/.top-wrapper-->

<div class="wrapper">




<h1 class="logo eightcol">

<?php
if ($woo_options['woo_texttitle'] != 'true' ) :
$logo = $woo_options['woo_logo'];
if ( is_ssl() ) { $logo = preg_replace("/^http:/", "https:", $woo_options['woo_logo']); }
?>

<a href="<?php echo home_url( '/' ); ?>" title="<?php bloginfo( 'description' ); ?>">
<img src="<?php if ($logo) echo $logo; else { echo get_template_directory_uri(); ?>/images/logos/argentum.png<?php } ?>" alt="<?php bloginfo( 'name' ); ?>" />
</a>

<?php else : ?>

<a href="<?php echo home_url( '/' ); ?>" title="<?php bloginfo( 'description' ); ?>">
<?php bloginfo( 'name' ); ?>
</a>

<?php endif; ?>

</h1><!--/.logo-->
<!-- Main navigation -->

<nav role="navigation" class="main-navigation">
<?php if (class_exists('woocommerce')) { ?>
<ul class="mini-cart">
<li>
<a href="<?php echo $woocommerce->cart->get_cart_url(); ?>" title="<?php _e('View your shopping cart', 'woothemes'); ?>">
<?php _e('Cart:', 'woothemes');?> <?php
echo $woocommerce->cart->get_cart_total();
?>
</a>
<?php

echo '<ul class="cart_list">';
if (sizeof($woocommerce->cart->cart_contents)>0) : foreach ($woocommerce->cart->cart_contents as $cart_item_key => $cart_item) :
$_product = $cart_item['data'];
if ($_product->exists() && $cart_item['quantity']>0) :
echo '<li><a href="'.get_permalink($cart_item['product_id']).'">';

echo $_product->get_image();

echo apply_filters('woocommerce_cart_widget_product_title', $_product->get_title(), $_product).'</a>';

if($_product instanceof woocommerce_product_variation && is_array($cart_item['variation'])) :
echo woocommerce_get_formatted_variation( $cart_item['variation'] );
endif;

echo '<span class="quantity">' .$cart_item['quantity'].' × '.woocommerce_price($_product->get_price()).'</span></li>';
endif;
endforeach;

else: echo '<li class="empty">'.__('No products in the cart.','woothemes').'</li>'; endif;
if (sizeof($woocommerce->cart->cart_contents)>0) :
echo '<li class="total"><strong>';

if (get_option('js_prices_include_tax')=='yes') :
_e('Total', 'woothemes');
else :
_e('Subtotal', 'woothemes');
endif;



echo ':</strong>'.$woocommerce->cart->get_cart_total();'</li>';

echo '<li class="buttons"><a href="'.$woocommerce->cart->get_cart_url().'" class="button">'.__('View Cart →','woothemes').'</a> <a href="'.$woocommerce->cart->get_checkout_url().'" class="button checkout">'.__('Checkout →','woothemes').'</a></li>';
endif;

echo '</ul>';

?>
</li>
</ul>
<?php } ?>
<?php
if ( function_exists( 'has_nav_menu') && has_nav_menu( 'primary-menu') ) {
wp_nav_menu( array( 'depth' => 6, 'sort_column' => 'menu_order', 'container' => 'ul', 'menu_id' => 'main-nav', 'menu_class' => 'nav', 'theme_location' => 'primary-menu' ) );
} else {
?>
<ul id="main-nav">
<?php
if ( isset($woo_options[ 'woo_custom_nav_menu' ]) AND $woo_options[ 'woo_custom_nav_menu' ] == 'true' ) {
if ( function_exists( 'woo_custom_navigation_output') )
woo_custom_navigation_output();
} else { ?>
<?php if ( is_page() ) $highlight = "page_item"; else $highlight = "page_item current_page_item"; ?>
<li class="<?php echo $highlight; ?>"><a href="<?php echo home_url( '/' ); ?>"><?php _e( 'Home', 'woothemes' ) ?></a></li>
<?php
wp_list_pages( 'sort_column=menu_order&depth=6&title_li=&exclude=' );
}
?>
</ul><!-- /#main-nav -->
<?php } ?>


<div class="clear"><!-- We need this for the drop downs --></div>

</nav><!--/.navigation-->

</div><!--/.wrapper-->

<div class="clear"></div>

</header>

<!-- Now we start the content wrapper -->

<div class="content-wrapper">

<div class="wrapper main-content row visible">

لینک به ارسال

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

wp-content / themes

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

این رو به کلاس #header .logo توی استایل قالبت اضافه کن :


width:auto;

لینک به ارسال

به گفتگو بپیوندید

هم اکنون می توانید مطلب خود را ارسال نمایید و بعداً ثبت نام کنید. اگر حساب کاربری دارید، برای ارسال با حساب کاربری خود اکنون وارد شوید .

مهمان
ارسال پاسخ به این موضوع ...

×   شما در حال چسباندن محتوایی با قالب بندی هستید.   حذف قالب بندی

  تنها استفاده از 75 اموجی مجاز می باشد.

×   لینک شما به صورت اتوماتیک جای گذاری شد.   نمایش به صورت لینک

×   محتوای قبلی شما بازگردانی شد.   پاک کردن محتوای ویرایشگر

×   شما مستقیما نمی توانید تصویر خود را قرار دهید. یا آن را اینجا بارگذاری کنید یا از یک URL قرار دهید.

×
×
  • اضافه کردن...