Announcement

Collapse
No announcement yet.

Display a 'From' price in the product summary if the product price is zero

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Display a 'From' price in the product summary if the product price is zero

    The product summary displays the product price. If the product price is zero, ie: prices are drawn from permutations, no price is displayed.

    To have a 'from' price showing the price of the cheapest permutation just add this to the product summary layout:

    Code:
    <actinic:block if="%3cactinic%3avariable%20name%3d%22PriceIsEnabled%22%20%2f%3e%20AND%20%28%3cactinic%3avariable%20name%3d%22ProductPriceRaw%22%20%2f%3e%20%3d%3d%200%29">    
                <actinic:block type="ComponentList" ><actinic:block type="PermutationList" >
                        <actinic:block if="%3cactinic%3avariable%20name%3d%22ListIndex%22%20%2f%3e%20%3d%3d%201" >
                        <span class="product-price">Price from: <actinic:variable name="PermutationPrice" /></span>
                        </actinic:block>
                </actinic:block></actinic:block>
            </actinic:block>
    So that the product summary layout looks a bit like this:

    Code:
    <actinic:block if="%3cactinic%3avariable%20name%3d%22IsFilteringEnabled%22%20%2f%3e%20AND%0d%3cactinic%3avariable%20name%3d%22MatchLayouts%22%20%2f%3e%20%3d%3d%20True%20AND%0d%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%29%20AND%0d%3cactinic%3avariable%20name%3d%22IsProductPageGenerated%22%20%2f%3e%20%3d%3d%20True" >
        <actinic:variable name="FilteredProductLayout" />
    </actinic:block>
    
    <actinic:block if="%28%3cactinic%3avariable%20name%3d%22IsFilteringEnabled%22%20%2f%3e%20AND%0d%3cactinic%3avariable%20name%3d%22MatchLayouts%22%20%2f%3e%20%3d%3d%20False%29%20OR%20%0d%3cactinic%3avariable%20name%3d%22IsFilteringEnabled%22%20%2f%3e%20%20%3d%3d%20False%20OR%0d%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Product%20Page%22%29%20OR%0d%3cactinic%3avariable%20name%3d%22IsProductPageGenerated%22%20%2f%3e%20%3d%3d%20False" >
    
    <actinic:block if="%3cactinic%3avariable%20name%3d%22IsProductFormUsed%22%20%2f%3e" >
    
    <form method="post" class="regularProductSummary" action="<actinic:variable name="OnlineScriptURL" value="Shopping Cart Script URL" />" novalidate>
            <input type="hidden" name="SID" value="<actinic:variable name="SectionID" />" />
            <input type="hidden" name="PAGE" value="PRODUCT" />           
            <actinic:block if="%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%29" >
                <input type="hidden" name="PAGEFILENAME" value="<actinic:variable name="SectionPageName" />" />
            </actinic:block>
            <actinic:block if="%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Product%20Page%22%29" >
                <input type="hidden" name="PAGEFILENAME" value="<actinic:variable name="ProductPageName" />" />
            </actinic:block>
            <Actinic:SECTION BLOB='<actinic:variable name="SectionCatFile" />'/>
            <actinic:block if="%3cactinic%3avariable%20name%3d%22IsHostMode%22%20%2f%3e" >
                <!-- Hidden field when in trial mode -->
                <input type="hidden" name="SHOP" value="<actinic:variable name="HiddenFields" />" />
            </actinic:block>
        </actinic:block>
    
    
    <div class="mini-product-summary">
        <a name="<actinic:variable name="EncodedProductAnchor" />"></a>
        <div class="mini-product-summary-image">
        <actinic:block if="%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%29%20AND%0d%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3d%3d%201%29" ><a href="<actinic:variable name="ProductPageName" />#SID=<actinic:variable name="SectionID" />"></actinic:block>
        <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%20AND%0d%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3d%3d%20%202%29" >
            <actinic:block if="%3cactinic%3avariable%20name%3d%22ExtendedInformationType%22%20%2f%3e%20%3d%3d%20%22Opens%20in%20a%20Pop%2dUp%20Window%22" >
                <a href="<actinic:variable name="ExtendedInfoPageEncoded" />" target="ActPopup" onclick="return ShowPopUp('<actinic:variable name="ExtendedInfoPageEncoded" />',<actinic:variable name="ExtInfoWindowWidth" />,<actinic:variable name="ExtInfoWindowHeight" />);">
            </actinic:block>
            <actinic:block if="%3cactinic%3avariable%20name%3d%22ExtendedInformationType%22%20%2f%3e%20%3d%3d%20%22Opens%20in%20the%20Same%20Window%22" >
                <a href="<actinic:variable name="ExtendedInfoPageName" />">
            </actinic:block>
        </actinic:block>    
            <actinic:variable name="ProductImageLayout" value="Small Product Image" />
        <actinic:block if="%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%29%20AND%0d%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3e%200%29" >
            </a>    
        </actinic:block>
        </div>
    
        <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22" >
            <actinic:block if="%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3d%3d%201%29" ><a href="<actinic:variable name="ProductPageName" />#SID=<actinic:variable name="SectionID" />">
            </actinic:block>
            <actinic:block if="%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3d%3d%20%202%29" >
                <actinic:block if="%3cactinic%3avariable%20name%3d%22ExtendedInformationType%22%20%2f%3e%20%3d%3d%20%22Opens%20in%20a%20Pop%2dUp%20Window%22" >
                    <a href="<actinic:variable name="ExtendedInfoPageEncoded" />" target="ActPopup" onclick="return ShowPopUp('<actinic:variable name="ExtendedInfoPageEncoded" />',<actinic:variable name="ExtInfoWindowWidth" />,<actinic:variable name="ExtInfoWindowHeight" />);">
                </actinic:block>
                <actinic:block if="%3cactinic%3avariable%20name%3d%22ExtendedInformationType%22%20%2f%3e%20%3d%3d%20%22Opens%20in%20the%20Same%20Window%22" >
                    <a href="<actinic:variable name="ExtendedInfoPageName" />">
                </actinic:block>
            </actinic:block>
            <actinic:block if="%3cactinic%3avariable%20name%3d%22UseDynamicPrices%22%20%2f%3e%20%3d%3d%20true%20AND%20%3cactinic%3avariable%20name%3d%22ProductComponentCount%22%20%2f%3e%20%3d%3d%200" >
                <actinic:variable name="ProductJavascriptLayout" />
            </actinic:block>
            <actinic:variable formatting="h2" encoding="actinic" name="ProductName" />
            <actinic:block if="%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%29%20AND%0d%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3e%200%29" >
                </a>
            </actinic:block>        
        </actinic:block>
    
        <div class="mini-product-summary-price">
            <actinic:block if="%3cactinic%3avariable%20name%3d%22PriceIsEnabled%22%20%2f%3e%20AND%20%28%3cactinic%3avariable%20name%3d%22ProductPriceRaw%22%20%2f%3e%20%3d%3d%200%29">    
                <actinic:block type="ComponentList" ><actinic:block type="PermutationList" >
                        <actinic:block if="%3cactinic%3avariable%20name%3d%22ListIndex%22%20%2f%3e%20%3d%3d%201" >
                        <span class="product-price">Price from: <actinic:variable name="PermutationPrice" /></span>
                        </actinic:block>
                </actinic:block></actinic:block>
            </actinic:block>
    
            <Actinic:PRICES PROD_REF="<actinic:variable Name="ProductID" />" RETAIL_PRICE_PROMPT="<Actinic:Variable Name="ProductPriceDescription"/>"><actinic:variable value="Marketing Price List" name="PriceListRetail" /></Actinic:PRICES>
        </div>
        </div>
        <div class="mini-product-summary-link">
        <actinic:block if="%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%29%20AND%0d%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3d%3d%201%29" ><a href="<actinic:variable name="ProductPageName" />#SID=<actinic:variable name="SectionID" />"></actinic:block>
        <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%20AND%0d%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3d%3d%20%202%29" >
            <actinic:block if="%3cactinic%3avariable%20name%3d%22ExtendedInformationType%22%20%2f%3e%20%3d%3d%20%22Opens%20in%20a%20Pop%2dUp%20Window%22" >
                <a href="<actinic:variable name="ExtendedInfoPageEncoded" />" target="ActPopup" onclick="return ShowPopUp('<actinic:variable name="ExtendedInfoPageEncoded" />',<actinic:variable name="ExtInfoWindowWidth" />,<actinic:variable name="ExtInfoWindowHeight" />);">
            </actinic:block>
            <actinic:block if="%3cactinic%3avariable%20name%3d%22ExtendedInformationType%22%20%2f%3e%20%3d%3d%20%22Opens%20in%20the%20Same%20Window%22" >
                <a href="<actinic:variable name="ExtendedInfoPageName" />">
            </actinic:block>
        </actinic:block>
        More Info
        <actinic:block if="%28%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%22Section%22%29%20AND%0d%28%3cactinic%3avariable%20name%3d%22ProductListNameLink%22%20%2f%3e%20%3e%200%29" >
            </a>    
        </actinic:block>
        </div>
    
    
    
    <actinic:block if="%3cactinic%3avariable%20name%3d%22IsProductFormUsed%22%20%2f%3e" >
          </form>
    </actinic:block>
    </actinic:block>
    Thank you.
    Jonathan Chappell
    Website Designer
    SellerDeck Website Designer
    Actinic to SellerDeck upgrades
    Graphicz Limited - www.graphicz.co.uk

    #2
    Neat, I don't suppose you know of any way to show the from price in the summary when using qty based pricing?
    Many Thanks
    Lee
    www.mdnsupplies.co.uk
    www.hookandloopfasteners.co.uk

    Comment


      #3
      Not off hand, it would take a bit of working out.
      Jonathan Chappell
      Website Designer
      SellerDeck Website Designer
      Actinic to SellerDeck upgrades
      Graphicz Limited - www.graphicz.co.uk

      Comment

      Working...
      X