Digital experiences for all disciplines
New Landing › How can we help? › Themeforest Theme Support › Neighborhood › Move Product Title
New Landing › How can we help? › Themeforest Theme Support › Neighborhood › Move Product Title
- This topic has 5 replies, 4 voices, and was last updated 7 years by David Martin – Support.
-
Posted in: Neighborhood
-
November 16, 2014 at 4:10 am #128577
Hi guys,
I browsed through a number of the other topics but can’t seem to get the answer I’m looking for…
I want to move the title from the page title location to above the price. Not change appearance, just the location.
Thanks
November 16, 2014 at 11:24 am #128595Hi
Add this to your custom css:
.woocommerce div.product .entry-title { display: block; margin-bottom: 10px; }
Open up content-single-product.php in the woocommerce folder and replace:
<div itemscope itemtype="http://schema.org/Product" id="product-<?php the_ID(); ?>" <?php post_class(); ?>> <div class="entry-title" itemprop="name"><?php the_title(); ?></div> <?php /** * woocommerce_show_product_images hook * * @hooked woocommerce_show_product_sale_flash - 10 * @hooked woocommerce_show_product_images - 20 */ do_action( 'woocommerce_before_single_product_summary' ); ?> <div class="summary entry-summary"> <div class="summary-top clearfix"> <div itemprop="offers" itemscope itemtype="http://schema.org/Offer"> <p itemprop="price" class="price"><?php echo $product->get_price_html(); ?></p> <meta itemprop="priceCurrency" content="<?php echo get_woocommerce_currency(); ?>" /> <?php if (!$catalog_mode) { ?><link itemprop="availability" href="http://schema.org/<?php echo $product->is_in_stock() ? 'InStock' : 'OutOfStock'; ?>" /><?php } ?> </div>
with this:
<div itemscope itemtype="http://schema.org/Product" id="product-<?php the_ID(); ?>" <?php post_class(); ?>> <?php /** * woocommerce_show_product_images hook * * @hooked woocommerce_show_product_sale_flash - 10 * @hooked woocommerce_show_product_images - 20 */ do_action( 'woocommerce_before_single_product_summary' ); ?> <div class="summary entry-summary"> <div class="summary-top clearfix"> <div class="entry-title" itemprop="name"><h1><?php the_title(); ?></h1></div> <div itemprop="offers" itemscope itemtype="http://schema.org/Offer"> <p itemprop="price" class="price"><?php echo $product->get_price_html(); ?></p> <meta itemprop="priceCurrency" content="<?php echo get_woocommerce_currency(); ?>" /> <?php if (!$catalog_mode) { ?><link itemprop="availability" href="http://schema.org/<?php echo $product->is_in_stock() ? 'InStock' : 'OutOfStock'; ?>" /><?php } ?> </div>
Let me know if it works, if not, please provide a link and login
– Kyle
November 17, 2014 at 2:52 am #128654Spot on Kyle.
Thanks!
November 17, 2014 at 8:55 am #128674No problem
January 3, 2017 at 5:49 pm #308681Is this still valid please? I can’t seem to find this in my content-single-product.php
Please help
January 3, 2017 at 5:55 pm #308683This is a very old thread. Please do not thread bump, create a new ticket as you have done and we will answer.
-
Posted in: Neighborhood
You must be logged in and have valid license to reply to this topic.