Support » Theme: Storefront » How to call an excerpt to a given page (not all product page) for a given catego

  • Resolved webdevtestus


    Hi, and thanks in advance.NOTE: NSFW site, maybe some hot images from eBooks covers, no nude but adult romance covers.

    I have wordpress+woocommerce+storefront+bookshop child theme.

    I have this page , Just in case NSFW site, ( that “brings” a product category, created with this shortcode

    [products limit="6" columns="1" category="mf" class="product-shortcode" cat_operator="AND" ]

    And left-aligned (float) with this CSS

    /*Align images to the left*/ div.columns-1 { float: left }

    Ok, I tried this code to get a summary/brief

    add_action( 'woocommerce_after_shop_loop_item_title', 'jdn_add_short_description', 9 ); function jdn_add_short_description() { // Description linked to product $url = get_the_permalink(); if( $url ) { echo '<span class="title-description"><a href="' . $url . '">' . get_the_excerpt() . '</a></span><br />'; } else { echo '<span class="title-description">' . get_the_excerpt() . '</span><br />'; } }

    BUT it gets the summary in ALL pages, not just this one

    What I need:

    To get a the product summary/brief JUST in this page, right aligned matching the left aligned images, AND get the Headline, Star Rating, Price and Get it now also right alignd and Up to math the image, so it all keeps aligned.

    is this possible via Code, php, Css, shortcode or is a misconfiguration of woocommere product?

    Thanks in advance.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Solved!

    I wrote my own shortcode adding the function with an array of desired pages to show excerpt and works!!

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.