Announcement

Collapse
No announcement yet.

Best Sellers

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

    Best Sellers

    Is there a way with best sellers to have them by section and not global, what we like to do is be able to say for each of our sections, they are the best selling X no items, but as it stands we can’t use this feature we will have to carry on doing it the same way as we did with version 7.

    #2
    I think the way to do this would be to create a new variable called something like 'ShowInBestSellerList'. Set the place of setting to 'Section'.

    Now enter a value for 'ShowInBestSellerList' for the different sections in your store. Becasue the products will automatically inherit this value from the section, this will mean that all the products in a section have the same value for 'ShowInBestSellerList'.

    Now you need to set up a best sellers list in your store that contains ALL the top selling products in the store.

    Then, in the library you need to duplicate the current best sellers list layout you are using and create a different best sellers list for each section in the store. So every section will have its own best sellers list.

    Then in each best sellers list you need to add a condition around the layout selector (within the list layout) that says

    ShowInBestSellerList == ??

    Where ?? is the value for 'ShowInBestSellerList' that you have set up for that section.

    So what is effectively happening is you are displaying the entire best sellers list on each section, but then filtering it via conditions so that only the products that are in that section will appear in the list.

    Comment


      #3
      I give that a try this afternoon.

      Comment


        #4
        Ok I may be doing some thing wrong, I have crated a verable called ShowInBestSellerList and duplicated the best sellets options, I now put in the top of the inner layout ShowInBestSellerList==1 and it diplaying homepage==1

        What have I done wrong?

        ta

        Comment


          #5
          Sorry Darren - I've just realised the solution I gave you won't work very well as you would need a different overall layout for each section as well as a different best sellers list for each section.

          All apologies - I should have thought it through more.

          To be honest - I'm stumped. If anyone knows how to display a different best sellers list on each section, feel free to contribute.

          Comment


            #6
            Hang on - I do have a solution.

            Comment


              #7
              1. Create a new variable called 'SectionName2'. Make it settable at the 'Section' level and give it a prompt of 'Enter Section Name'.
              2. Make sure the 'Initial Value' is 'Use Parent' and the 'Top Level Value' is blank.
              3. OK - now edit the layout called 'Sidebar Best Sellers List' or whatever best sellers list you are using.
              4. Highlight the pink layout selector in that layout and click the 'Insert Block' button.
              5. Copy and paste the following condition in:
              6. <actinic:variable name="SectionName2" /> == <actinic:variable name="SectionName" />
              7. OK - now go to one of your sections and enter a value for 'Enter Section Name' which is IDENTICAL to the actual section name. Repeat this for all the sections in the store.
              Now set up the massive best seller list containing everything as I described before.

              The condition you have inserted into the list layout will mean that only the products in the current section will be shown.

              Comment


                #8
                Is this what I should have or am I reading the isnstructions wrong?

                <!--New Best seller layout//-->
                <actinic:variable name="SectionName2" /> == <actinic:variable name="SectionName" />
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                <td width="33" align="left" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                <td align="left" valign="top"><div align="center">
                Best Seller </div></td>
                </tr>
                <tr>
                <td align="left" valign="top">
                <div align="center">
                <Actinic:Variable Name="ProductName"/>
                </div>
                </td>
                </tr>
                <tr>
                <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr align="left" valign="top">
                <td width="71%"><actinic:block if="%3cactinic%3avariable%20name%3d%22ProductImageFileName%22%20%2f%3e%20%21%3d%20%22%22" >
                <img src="<actinic:variable name="ProductImageFileName" />" width="75" alt="<actinic:variable name="ProductName" />" />
                </actinic:block></td>
                <td width="29%">
                <actinic:block php="true" >
                $sShort = "";
                $nCount = 0;
                $sOriginal = '<actinic:variable encoding="perl" name="ProductDescription" selectable="false" />';
                $stemp=str_replace( "<b>","",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace("!!","",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace(chr(60),"",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace(chr(62),"",$sOriginal);
                $sOriginal =$stemp;
                foreach(explode(" ", $sOriginal) as $sWord)
                {
                if ($nCount > 20)
                {
                $sShort .= "...";
                break;
                }
                $sShort .= $sWord . " ";
                $nCount++;
                }

                echo $sShort;

                </actinic:block>
                </td>
                </tr>
                </table></td>
                </tr>
                </table></td>
                <td width="33" align="left" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                <td align="left" valign="top"><div align="center">
                Best Seller </div></td>
                </tr>
                <tr>
                <td align="left" valign="top">
                <div align="center">
                <Actinic:Variable Name="ProductName"/>
                </div>
                </td>
                </tr>
                <tr>
                <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr align="left" valign="top">
                <td width="71%"><actinic:block if="%3cactinic%3avariable%20name%3d%22ProductImageFileName%22%20%2f%3e%20%21%3d%20%22%22" >
                <img src="<actinic:variable name="ProductImageFileName" />" width="75" alt="<actinic:variable name="ProductName" />" />
                </actinic:block></td>
                <td width="29%">
                <actinic:block php="true" >
                $sShort = "";
                $nCount = 0;
                $sOriginal = '<actinic:variable encoding="perl" name="ProductDescription" selectable="false" />';
                $stemp=str_replace( "<b>","",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace("!!","",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace(chr(60),"",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace(chr(62),"",$sOriginal);
                $sOriginal =$stemp;
                foreach(explode(" ", $sOriginal) as $sWord)
                {
                if ($nCount > 20)
                {
                $sShort .= "...";
                break;
                }
                $sShort .= $sWord . " ";
                $nCount++;
                }

                echo $sShort;

                </actinic:block>
                </td>
                </tr>
                </table></td>
                </tr>
                </table></td>
                <td width="33" align="left" valign="top">
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                <td align="left" valign="top"><div align="center">
                Best Seller </div></td>
                </tr>
                <tr>
                <td align="left" valign="top">
                <div align="center">
                <Actinic:Variable Name="ProductName"/>
                </div>
                </td>
                </tr>
                <tr>
                <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr align="left" valign="top">
                <td width="71%"><actinic:block if="%3cactinic%3avariable%20name%3d%22ProductImageFileName%22%20%2f%3e%20%21%3d%20%22%22" >
                <img src="<actinic:variable name="ProductImageFileName" />" width="75" alt="<actinic:variable name="ProductName" />" />
                </actinic:block></td>
                <td width="29%">
                <actinic:block php="true" >
                $sShort = "";
                $nCount = 0;
                $sOriginal = '<actinic:variable encoding="perl" name="ProductDescription" selectable="false" />';
                $stemp=str_replace( "<b>","",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace("!!","",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace(chr(60),"",$sOriginal);
                $sOriginal =$stemp;
                $stemp=str_replace(chr(62),"",$sOriginal);
                $sOriginal =$stemp;
                foreach(explode(" ", $sOriginal) as $sWord)
                {
                if ($nCount > 20)
                {
                $sShort .= "...";
                break;
                }
                $sShort .= $sWord . " ";
                $nCount++;
                }

                echo $sShort;

                </actinic:block>
                </td>
                </tr>
                </table></td>
                </tr>
                </table>
                </td>
                </tr>
                </table>

                TA

                Comment


                  #9
                  I am eather been thick or doing some thing wrong, I have modified the best seller template to show 3 products and now what I am getting is eather noting or if I pit the Block / if block with ref to the actinic verables above or if I take that out in sted of getting 3 items I get 9 so what am I doing wrong, and do I change the item on the best seller list to give a specific section!

                  help!

                  Comment


                    #10
                    Darren -
                    <!--New Best seller layout//-->
                    <actinic:variable name="SectionName2" /> == <actinic:variable name="SectionName" />
                    This conditional code needs to be within a conditional 'block' tag.
                    I have modified the best seller template to show 3 products
                    No - you need to have a best sellers list that shows all the products in your store and then the conditional statement I gave you will limit the best sellers list to only showing the products that are in the current section. You will have no control over how many products appear in the list.

                    I'm sorry to say this, but your requirements are so specific, I don't think Actinic will ever be able to produce a best sellers list as you need it - even if you do manage to implement my suggestion.

                    Comment


                      #11
                      I don't know if this is still a valid thread however I wondered if the section specific bestsellers as described by Chris would incorporate everything from each top level (and sub) section or *only* from the section being viewed at that moment (no matter how far down the 'tree' it was).
                      Thanks

                      Jos Medinger

                      Tel : 01978 843 962
                      www.internetology.co.uk
                      Actinic / E-Commerce Hosting, Design & SEO
                      ______________________________________

                      Comment


                        #12
                        The code looks like it only displays items Best Seller items that are also in the current Section.

                        If that's not what you want, it may be best posting your requirements in a new thread to keep this one on-topic.
                        Norman - www.drillpine.biz
                        Edinburgh, U K / Bitez, Turkey

                        Comment

                        Working...
                        X