Announcement

Collapse
No announcement yet.

Suggested New Articles for KB

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

    #46
    resize browser to see what it looks like for your customers?

    in firefox, right click on your bookmarks toolbar, and click 'add new'.

    call it: '800x600'
    and paste this in the location:
    javascript:top.resizeTo(800,600);
    the most common resolution for latops is 1024x768
    for 1024x768 call it: '1024x768'
    and paste this in the location:
    javascript:top.resizeTo(1024,768);
    go to any page, and then click your shiny new bookmarklet.

    your browser should snap to your selected size.

    Comment


      #47
      quickly make the code for a link without typing.

      another bookmarklet.
      HTML Code:
      javascript:function htmlEscape(s){s=s.replace(/&/g,'&amp;');s=s.replace(/>/g,'&gt;');s=s.replace(/</g,'&lt;');return s;} function linkEscape(s){s=s.replace(/&/g,'&amp;');s=s.replace(/"/,'&quot;');return s} h = '<a href="' + linkEscape(location.href) + '">' + htmlEscape(document.title) + '</a>'; with(window.open().document){write(h+'<form name=f><textarea  name=a rows=5 cols=80 wrap=hard>'+htmlEscape(h)+'</textarea></form>'); close(); f.a.select(); } void 0


      paste this into the url of a bookmark in your bookmark toolbar.

      navigating to a page, then clicking this bookmarklet, causes your browser to craft a link, to the current page, uwing its title as the link text.

      useful for hard coding links into fragments.

      Comment


        #48
        V8 - how to show 2 prices eg RRP v discounted price

        Create a product variable called RRP. Store the full price in RRP, and put the actual discounted price in the Actinic price.

        Then edit the pricing layout to show the RRP variable after the price (in a BLOCK IF so that it only shows if it's not empty). e.g. "Price: £12.99 (RRP: £19.99)".

        You can put the RRP bit in a paler colour so as not to confuse.

        Comment


          #49
          V8 - create a brochure page to show bestsellers as a separate page

          1. Create a Brochure page called Best Sellers
          2. Navigate to the inner layout for your Brochure Page, in my case it is Standard Brochure Page Bulk and is in the Library under Web Page Inner Layout.
          3. Copy and paste the following into the layout, above BrochureFragmentList Layout selector.


          Code:
          <actinic:block if="%3cactinic%3avariable%20name%3d%22BrochureName%22%20%2f%3e%20%3d%3d%20%22Best%20Sellers%22">
          <actinic:variable name="BestSellersList" value="Home Page Best Sellers List" />
          </actinic:block>

          Comment


            #50
            Fixing .XX prices where the last 0's are dropped

            If you use a number (e.g. RRP) and it ends either .x0 or .00 then it drops the last digit (or two), e.g.

            10.50 returns 10.5
            9.00 is displayed as 9

            To fix this, do the following:

            PHP:
            PHP Code:
            <actinic:block php="true" >
              
            $rrp '<actinic:variable name="RRP" />';
              
            $rrp sprintf('%01.2f'$rrp);
              echo 
            $rrp;
              unset(
            $rrp);
            </
            actinic:block
            JS:
            Code:
            rrp = rrp.toFixed(2);

            Comment


              #51
              How to change the width of the address book in the second checkout page

              http://community.actinic.com/showthread.php?t=31382

              Comment


                #52
                I added it in after your post this morning Duncan as there have been 3 posts in as many days for the same.


                Bikster
                SellerDeck Designs and Responsive Themes

                Comment


                  #53
                  Display 3 related items in a row

                  instead of one underneath the other

                  Design/Library/Layouts/Related Products/Standard Product Related Products Lists

                  Edit list layout settings

                  Edit Rows and Columns

                  Change Middle Row to 3

                  Then go to Design View for Mini Product Related Products Item

                  About line 16 is:

                  <hr size="1" align="CENTER" width="xxx">

                  set thewidth xxx to your choice, probably 33%

                  Comment


                    #54
                    V8 - Add link to sitemap on brochure home page

                    Go to the design layout for the Catalog pages and find the 'Horizontal Nav Bar Text Links' layout. In the code pane you will see a reference to 'Sitemap Text Link' - simple remove the blockif and /block immediately around the 'Sitemap Text Link' (leave the other blockif and /block around it).

                    Now copy the code including the remaining blockif and /block around the 'Sitemap Text Link' and paste it into a similar position on the Brochure layout 'Brochure Nav Bar Text Link List' layout code, at the end of the code, or where you want it to appear.

                    Comment


                      #55
                      specify a Cut off date for Orders

                      For anyone else interested, the code in the AUG needs to be amended.

                      This is how it currently appears, which calculates the time on the user's computer. This means that a customer in New York, for example, would not see the message until 4pm New York time, which is 9pm UK Time, so would not realise that the cut-off time had passed. A customer in Amsterdam would see the message at 4pm Amsterdam time, which is 3pm UK time, so you could lose his order because he would think the cut-off time had passed.

                      <script language=JavaScript>
                      now = new Date();
                      if ( now.getHours() >= 16 ) document.write('<span style="color:red;">Warning text here</span>');
                      </script>
                      The amended code is:-

                      <script language=JavaScript>
                      now = new Date();
                      if ( now.getUTCHours() >= 16 ) document.write('<span style="color:red;">Warning text here</span>');
                      </script>
                      This calculates the time according to Universal Coordinated Time (UTC), and will display correctly on the user's computer provided it is set correctly for their time zone.

                      You can expand on this further, by having different messages according to the day of the week as follows:-

                      <script language=JavaScript>
                      now = new Date();
                      if ( now.getUTCHours() >= 16 )
                      if ( now.getUTCDay() == 1)
                      document.write('<span style="color:red;">Monday warning text here</span>');
                      </script>
                      <script language=JavaScript>
                      now = new Date();
                      if ( now.getUTCHours() >= 16 )
                      if ( now.getUTCDay() == 2)
                      document.write('<span style="color:red;">Tuesday warning text here</span>');
                      </script>
                      <script language=JavaScript>
                      now = new Date();
                      if ( now.getUTCHours() >= 16 )
                      if ( now.getUTCDay() > 0)
                      if ( now.getUTCDay() < 6)
                      document.write('<span style="color:red;">Monday to Friday warning text here</span>');
                      </script>
                      <script language=JavaScript>
                      now = new Date();
                      if ( now.getUTCDay() == 0)
                      document.write('<span style="color:red;">Sundaywarning text here</span>');
                      </script>
                      (The last one assumes that there is no delivery service on Sundays regardless of time, hence the absence of the time element)

                      You can have as many of these as you want, and only those which meet the day and time criteria will be shown.

                      This could even be used for marketing messages, so you could create a special offer which is only available on Fridays until 2pm for example.

                      The Universal Coordinated Time (UTC) is the time set by the World Time Standard, and is equivalent to GMT. However, you would have to adjust the cut-off time during the summer months, when GMT is advanced an hour, so the above example would work ok in winter for a 4pm cut-off, but 16 would need to be changed to 15 during summer time.
                      __________________

                      Comment


                        #56
                        Originally posted by pinbrook View Post
                        If you have add to cart button within extended info (as pop up) you click on add to cart and the site then loads in to the pop up rather than than main site page - to prevent this

                        You need to make sure that the each page open has a unique name. Add this JavaScript in the overall layout.

                        Code:
                        <script language="JavaScript">
                        <!-- (V11)
                        // set the window name to unique value
                        Now = new Date();
                        var WindowName = "W" + Now.getTime();
                        window.name = WindowName;
                        //-->
                        </script>
                        Then in the popup window you need to give the FORM a name "popform" and have some JavaScript in the BODY tag like

                        Code:
                        onload="if ( opener ){ if ( opener.WindowName ) document.forms.popform.target = opener.WindowName; }"

                        This is clear and concise but to a complete Actinic newbie makes little sence! Which page files should be edited to contain these strings and what elements (if any) need to change within the string to relate to a page/file name?
                        Webfaced - Award-Winning SellerDeck Web Design Agency

                        Comment


                          #57
                          Hi Dominic.

                          This is pretty advanced stuff so if you are new at Actinic I would steer clear of it.

                          The short answer is the first piece of Javascript needs to go within the <head> tags of the overall layout(s) used by your store pages. If you don't know what an overall layout is, read the 'Help With Design' section of the help before you do anything else.

                          The second part of the guide requires editing the 'Extended Information Design' called 'Includes Add to Cart Button'. You need to edit the <body> tag within this file and also add 'name="popform" ' into the <form> tag.

                          Again, if what I've just said doesn't make any sense, I suggest you read the help or book yourself on an Actinic training course

                          Comment

                          Working...
                          X