Announcement

Collapse
No announcement yet.

Prices on 'trade' section pages

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

    Prices on 'trade' section pages

    Hi,

    I was once given a bit of code by Norman to display product prices on section pages:

    Code:
    <actinic:block php="true" >$prodprice = '';</actinic:block>			
    <actinic:block type="ProductList" >
    	<actinic:block if="%3cactinic%3avariable%20name%3d%22ProductType%22%20%2f%3e%20%21%3d%202" >
    		<actinic:block php="true" >
    		 if ( trim($prodprice) == '' )
    			{
    			$prodprice = <<<ENDOFCODE
    			<actinic:block type="PriceList" >
    				<actinic:variable name="PriceLayout" />
    			</actinic:block> 
    ENDOFCODE;
    			}
    		</actinic:block>
    	</actinic:block>
    </actinic:block>
    <actinic:block php="true" >echo $prodprice;</actinic:block>
    I'm currently having an issue with getting this to work for trade customers though. My site only displays product prices to customers that are logged in but I can't seem to get those prices to display on my section pages as well as the actual product page e.g. http://www.wholesaleelectricalsuppli...g/lcd-tvs.html

    Does anybody know if this is possible and how would I go about it?

    #2
    That code you're using only has the basic price layout included in it, it does not have the trade price code included. If you take a look on the product layout, you will see the price layout code is far bigger, you will need to merge the code from a product layout into the section layout, with some fettling and adjusting, pain being you have to upload to see the changes. I can't recall the exact answer but i can recall discussing it on the forum a considerable amount of time ago, so if you get stuck, might be worth a trawl for that. From memory it's to do with the <actinic prices> tag, that is how trade prices are shown. Have you checked the KB too, well worth a check in there.

    Comment


      #3
      Try replacing:
      Code:
      			<actinic:block type="PriceList" >
      				<actinic:variable name="PriceLayout" />
      			</actinic:block>
      with:
      Code:
               <actinic:block if="%3cactinic%3avariable%20name%3d%22PriceIsEnabled%22%20%2f%3e">
      				<Actinic:PRICES PROD_REF="<actinic:variable Name="ProductID" />" RETAIL_PRICE_PROMPT="<Actinic:Variable Name="ProductPriceDescription"/>">
      					<actinic:variable name="PriceListRetail" />
                  </Actinic:PRICES>
               </actinic:block>
               <actinic:block if="%3cactinic%3avariable%20name%3d%22ProductPriceIsEnabled%22%20%2f%3e%20%3d%3d%20False">
      	         <Actinic:NOTINB2B><br /><actinic:variable name="ProductPriceNotEnabledMessage" /></Actinic:NOTINB2B>
               </actinic:block>
               <actinic:block if="%3cactinic%3avariable%20name%3d%22IsCustomerMessageUsed%22%20%2f%3e">
                  <br />
                  <Actinic:PRICE_EXPLANATION PROD_REF="<actinic:variable Name="ProductID" />" COMPONENTID=-1><Actinic:Variable Name="RetailCustomerMessage"/></Actinic:PRICE_EXPLANATION>
               </actinic:block>
      This may generate more price info than you want so you'll have to work out how to trim it down.
      Norman - www.drillpine.biz
      Edinburgh, U K / Bitez, Turkey

      Comment


        #4
        Hi Norman,

        Thanks for your help - adding that code displays the message to retail customers that the product is unavailable.

        However, it doesn't display the price for customers that are logged in.

        Comment

        Working...
        X