Announcement

Collapse
No announcement yet.

Displaying Price in Section Link

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

    Displaying Price in Section Link

    Could somebody please help.

    Is it possible to display the product price in the SectionLink? At present, my sectionlink mearly displays a product image and title. It would be ideal to display the price as well.

    Thanks
    "Opportunities multiply as they are seized." - Sun Tzu

    #2
    I still don't think this is possible as a section could contain many products so it would not know which price to use.. hence in v7 it was always manually entered.

    The v8 trick is to set the products as duplicate to replicate section layouts and link back to the product proper once clicked ... seem to recall Duncan (drounding) had some code for this at the early days of the v8 forum


    Bikster
    SellerDeck Designs and Responsive Themes

    Comment


      #3
      Originally posted by JSnow
      Could somebody please help.

      Is it possible to display the product price in the SectionLink? At present, my sectionlink mearly displays a product image and title. It would be ideal to display the price as well.

      Thanks
      It can be done, but it is not as simple as adding a variable and away you go.

      You can create a layout and add to cart and as jonty rightly points out, you can then either a) use the extended info page to display more details (not good for seo tho) or b) duplicate the product etc...

      HTH
      Affordable solutions for busy professionals.
      Website Maintenance | UK Web Hosting

      Comment


        #4
        <actinic:block type="ProductList" >
        <actinic:block type="PriceList" >
        <actinic:variable name="PriceLayout" />
        </actinic:block>
        </actinic:block>

        seems to do the trick for me within my section layout, please note this is base on 1 product per section.
        Ben Adcock
        Caged Fish Web Design

        Comment


          #5
          Originally posted by mediacat
          <actinic:block type="ProductList" >
          <actinic:block type="PriceList" >
          <actinic:variable name="PriceLayout" />
          </actinic:block>
          </actinic:block>
          This seems to work, which upsets me greatly as we have always typed them in after being reliably assured by Actinic it could not be done. Thank you Ben for being cleverer than Actinic!!!

          Will have a greater look later to double check it works ok for us and report back.
          Cheers

          David
          Located in Edinburgh UK

          http://twitter.com/mcfinster

          Comment


            #6
            Have not tried yet but nice one


            Bikster
            SellerDeck Designs and Responsive Themes

            Comment


              #7
              Bam!!!!

              And there it is... The Meaning Of Life!!!!

              Thanks Ben, this worked like a charm.

              Someone should make this a sticky!!!!
              "Opportunities multiply as they are seized." - Sun Tzu

              Comment


                #8
                Agrred, it should also be added to the AUG with haste, will at least save some people days and days of work!
                Cheers

                David
                Located in Edinburgh UK

                http://twitter.com/mcfinster

                Comment


                  #9
                  damn...I spent flipping ages trying to do that yesterday!
                  why didn't I see this thread!!?

                  *adds to her to-do list*
                  Tracey

                  Comment


                    #10
                    And there it is... The Meaning Of Life!!!!
                    More like the circle of Actinic Life. The community's helped me lots in the past, its about time to give something back.
                    Ben Adcock
                    Caged Fish Web Design

                    Comment


                      #11
                      And it would appear that it is now my turn...

                      The following will place an add to cart button into the section link without the need for all the product duplicates etc. It also adds the first ten words of the full description to the section link.

                      NOTE: It only works if you have a single product per page.

                      EDIT...
                      Last edited by JSnow; 18-Jun-2007, 07:30 AM. Reason: See below. Code enclosed in scroll box by Pinbrook... Thanks
                      "Opportunities multiply as they are seized." - Sun Tzu

                      Comment


                        #12
                        I'd love to know how to encapsulate that into a scroll bar window as I have seen in other posts.
                        "Opportunities multiply as they are seized." - Sun Tzu

                        Comment


                          #13
                          Code:
                          <actinic:block if="%3cactinic%3avariable%20name%3d%22IsProductFormUsed%22%20%2f%3e">
                          <form method="post" action="<actinic:variable name="OnlineScriptURL" value="Shopping Cart Script URL" />">
                          <input type="hidden" name="SID" value="<Actinic:Variable Name="SectionID"/>" />
                          <input type="hidden" name="PAGE" value="PRODUCT" />
                          <input type="hidden" name="PAGEFILENAME" value="<actinic:variable name="SectionPageName" />" />
                          <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="product_list">
                          <div class="image_product"><a href="<actinic:block if="%3cactinic%3avariable%20name%3d%22IsLoginPageSuppressed%22%20%2f%3e%20AND%0d%3cactinic%3avariable%20name%3d%22UnregCustomersAreNotAllowed%22%20%2f%3e" ><actinic:variable name="SectionPageName" /></actinic:block><actinic:block if="%28%3cactinic%3avariable%20name%3d%22IsLoginPageSuppressed%22%20%2f%3e%20%3d%3d%20false%29%20OR%0d%28%3cactinic%3avariable%20name%3d%22UnregCustomersAreNotAllowed%22%20%2f%3e%20%3d%3d%20false%29" ><actinic:variable name="SectionURL" /></actinic:block>" target="_self"><img alt="<actinic:variable name="SectionName" encoding="strip"/>" src="<actinic:variable Name="SectionImageFileName"/>" border="0" /></a></div>
                          <div><h3 class="product"><a href="<actinic:block if="%3cactinic%3avariable%20name%3d%22IsLoginPageSuppressed%22%20%2f%3e%20AND%0d%3cactinic%3avariable%20name%3d%22UnregCustomersAreNotAllowed%22%20%2f%3e" ><actinic:variable name="SectionPageName" /></actinic:block><actinic:block if="%28%3cactinic%3avariable%20name%3d%22IsLoginPageSuppressed%22%20%2f%3e%20%3d%3d%20false%29%20OR%0d%28%3cactinic%3avariable%20name%3d%22UnregCustomersAreNotAllowed%22%20%2f%3e%20%3d%3d%20false%29" ><actinic:variable name="SectionURL" /></actinic:block>" target="_self"><span style="color:<actinic:variable name="Palette2" />"><actinic:variable name='SectionName'/></span></a></h3></div>
                          <actinic:block type="ProductList" >
                          <div style="float: right;">
                          <actinic:block if="%3cactinic%3avariable%20name%3d%22IsAddToCartButtonShown%22%20%2f%3e%20AND%20%0d%28%3cactinic%3avariable%20name%3d%22NumberAttributesInPushButtonGrid%22%20%2f%3e%20%3d%3d%200%29" >
                          <actinic:variable name="AddToCartButton" /><br>
                          <span class="actrequired"><Actinic:Variable Name="QuantityPrompt"/></span><br>
                          <input type="text" name="Q_<Actinic:Variable Name="ProductReference"/>" size="4" value="<Actinic:Variable Name="DefaultQuantity"/>" class="form_input_general" />
                          </actinic:block>
                          </div>
                          <actinic:block type="PriceList" >
                          <b><actinic:variable name="PriceLayout" /></b><br><br>
                          </actinic:block>
                          <actinic:block php="true" >
                          $sShort = "";
                          $nCount = 0;
                          $sOriginal = '<actinic:variable encoding="perl" name="ProductDescription" selectable="false" />';
                          foreach(explode(" ", $sOriginal) as $sWord)
                          {
                          if ($nCount > 10)
                          {
                          $sShort .= "...";
                          break;
                          }
                          $sShort .= $sWord . " ";
                          $nCount++;
                          }
                          echo $sShort;
                          </actinic:block>
                          </actinic:block>
                          <br><a href="<actinic:block if="%3cactinic%3avariable%20name%3d%22IsLoginPageSuppressed%22%20%2f%3e%20AND%0d%3cactinic%3avariable%20name%3d%22UnregCustomersAreNotAllowed%22%20%2f%3e" ><actinic:variable name="SectionPageName" /></actinic:block><actinic:block if="%28%3cactinic%3avariable%20name%3d%22IsLoginPageSuppressed%22%20%2f%3e%20%3d%3d%20false%29%20OR%0d%28%3cactinic%3avariable%20name%3d%22UnregCustomersAreNotAllowed%22%20%2f%3e%20%3d%3d%20false%29" ><actinic:variable name="SectionURL" /></actinic:block>" target="_self">More Info...</a>
                          </div>
                          
                          <actinic:block if="%3cactinic%3avariable%20name%3d%22IsProductFormUsed%22%20%2f%3e">
                          </form>
                          </actinic:block>
                          Now this is very interesting, thanks for posting it.

                          I've been playing about with it with a view to making a few modes to fit in with my design, I'm wondering what I need to do to remove the quantity box, I've tried the obvious hack of removing the
                          Code:
                          <span class="actrequired"><Actinic:Variable Name="QuantityPrompt"/></span><br>
                          <input type="text" name="Q_<Actinic:Variable Name="ProductReference"/>" size="4" value="<Actinic:Variable Name="DefaultQuantity"/>" class="form_input_general" />
                          but it breaks the code

                          Comment


                            #14
                            how about removing the prompt value and using input type=hidden?
                            Bill
                            www.egyptianwonders.co.uk
                            Text directoryWorldwide Actinic(TM) shops
                            BC Ness Solutions Support services, custom software
                            Registered Microsoft™ Partner (ISV)
                            VoIP UK: 0131 208 0605
                            Located: Alexandria, EGYPT

                            Comment


                              #15
                              Bill's idea works if you don't want the quantity.

                              Back to JSnow's code, if you have a structure of

                              section ie online catalog
                              section (books)
                              subsection (great expectations)
                              product (great expectations)
                              sub section (pride and predjudice)
                              product (pride and predjudice)

                              you will need to either define another section layout or revert to section description as you will loose section description as books level.

                              But its a neat bit of coding

                              Comment

                              Working...
                              X