Announcement

Collapse
No announcement yet.

RTS Message if insufficient stock

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

    RTS Message if insufficient stock

    I'm having trouble figuring out what controls the messages you get when you try to order an item and there is insufficient stock with Real Time Stock switched on.

    Example page :

    http://www.jeans-direct.com/acatalog...les_Jeans.html

    If you order more than one of the first product in the list you get a message above all the products :

    The following product(s) can not be added to the cart.
    You can find the error description(s) by following the link(s).
    Wrangler® Miles Stone Creased-30W30L
    and the Quantity box for the product turns red.

    Clicking on the Wrangler link doesn't really do anything and there is no explanation why you can't order.

    Can anyone shed some light on where to look to change as this feels like Javascript to me....

    thanks

    Goz.
    Elysium:Online - Official Accredited SellerDeck Partner
    SellerDeck Design, Build, Hosting & Promotion
    Based in rural Northants

    #2
    I can see why clicking on the link to take you to the product doesn't seem to work...

    it's looking to go to aW16RQE11A_3632 whereas in the HTML is named 'aW16RQE11A_2d3632' - it's got an extra 2d in the middle.

    ??
    Elysium:Online - Official Accredited SellerDeck Partner
    SellerDeck Design, Build, Hosting & Promotion
    Based in rural Northants

    Comment


      #3
      Slowly getting somewhere..... the EncodedProductAnchor is producing the anchor with _21 rather than ! and _2d rather than -
      Elysium:Online - Official Accredited SellerDeck Partner
      SellerDeck Design, Build, Hosting & Promotion
      Based in rural Northants

      Comment


        #4
        I've tried every Encoding for that variable and it always ends up with _21 rather than ! and _2d rather than -

        Probably time to give up for a while....
        Elysium:Online - Official Accredited SellerDeck Partner
        SellerDeck Design, Build, Hosting & Promotion
        Based in rural Northants

        Comment


          #5
          Originally posted by Goz View Post
          I'm having trouble figuring out what controls the messages you get when you try to order an item and there is insufficient stock with Real Time Stock switched on.

          Example page :

          http://www.jeans-direct.com/acatalog...les_Jeans.html

          If you order more than one of the first product in the list you get a message above all the products :


          and the Quantity box for the product turns red.

          Clicking on the Wrangler link doesn't really do anything and there is no explanation why you can't order.

          Can anyone shed some light on where to look to change as this feels like Javascript to me....

          thanks

          Goz.
          On the page after adding 2 products and getting the error message, scroll down
          to the product, the explanation is there under the add to cart button at least
          on this browser (firefox 3.6).

          What happens is you press the add to cart, this calls the add to cart perl
          script which checks various condition including stock for product, if it finds
          any errors it sends a new html file that is displayed and this file includes the
          link which should be a link to the product anchor. It also adds an error into the page to describe the problem. If all is ok the script
          displays the cart bounce page. This is all handled in the perl script and is part of the add to cart system.

          Malcolm

          SellerDeck Accredited Partner,
          SellerDeck 2016 Extensions, and
          Custom Packages

          Comment


            #6
            This is still a problem for me and it's so far stumped the finest Actinic brains.

            The bottom line is that on this site, a typical duplicated product code of

            50109450-3430
            when used in

            HTML Code:
            <a name="<actinic:variable name="EncodedProductAnchor" />">
            produces HTML that is

            HTML Code:
            <a name="a5_2150109450_2d3430">
            when it should be

            HTML Code:
            <a name="a5!50109450-3430">

            I have tried all the Encoding types and get the same result. There must be something else affecting this - but I haven't got a clue about where to start looking. Can any of the finest Community brains give me a nudge in a possible right direction?

            thanks

            Goz.
            Elysium:Online - Official Accredited SellerDeck Partner
            SellerDeck Design, Build, Hosting & Promotion
            Based in rural Northants

            Comment


              #7
              The Actinic Variable EncodedProductAnchor is an "a" followed the product ID with all non alphanumerics replaced with underscore then the HEX equivalent of that character.

              E.g. Product ID ABC123 will have an anchor aABC123 and Product ID ABC-123 will have anchor aABC_2d123

              I've no idea what's going wrong with your RTS links however.
              Norman - www.drillpine.biz
              Edinburgh, U K / Bitez, Turkey

              Comment


                #8
                Am I looking at the wrong thing?

                The link to that anchor tag - as created by RTS in v10 - is

                HTML Code:
                <a href="javascript: location.hash = 'a50109450-3834'; void 0">
                Should that be replacing the hyphen with _2d ?
                Elysium:Online - Official Accredited SellerDeck Partner
                SellerDeck Design, Build, Hosting & Promotion
                Based in rural Northants

                Comment


                  #9
                  Might be one for support. The product layout when the anchor works correctly it's anchoring below the ADD TO CART and quantity, CartError it's wrapping the text around ADD TO CART.
                  Peblaco

                  Comment


                    #10
                    Thanks Louise.

                    I've been talking to support for a week....

                    I'll take a look at the layout.
                    Elysium:Online - Official Accredited SellerDeck Partner
                    SellerDeck Design, Build, Hosting & Promotion
                    Based in rural Northants

                    Comment


                      #11
                      This looks like a bug. Bet Actinic only tested RTS with plain alphanumeric Product References. Or even worse, with the auto product references which are purely numeric.

                      If you try this with a product using a purely alphanumeric reference I expect it to work.

                      What happens if the product is a Duplicate (again using using a purely alphanumeric reference) should also be checked as I'm not sure what will happen then.
                      Norman - www.drillpine.biz
                      Edinburgh, U K / Bitez, Turkey

                      Comment


                        #12
                        Originally posted by Goz View Post

                        produces HTML that is

                        HTML Code:
                        <a name="a5_2150109450_2d3430">
                        when it should be

                        HTML Code:
                        <a name="a5!50109450-3430">
                        Goz.
                        Actinic is first adding _ for each non alphanumeric but then adding the ASCII code of the character
                        ! 0x21
                        - 0x2d

                        A bit of a bug for sure, at least one site in V10.0.3 and one in V8.0.5 is doing this on my machine, so this is nothing to do with RTS.

                        Malcolm

                        SellerDeck Accredited Partner,
                        SellerDeck 2016 Extensions, and
                        Custom Packages

                        Comment


                          #13
                          The anchor tags are correct. Actinic always escapes (with _nn) all non alphanumerics when creating anchors. The variable EncodedProductAnchor does this.

                          What's wrong is that the RTS code is not creating a corresponding _nn sequence for all non alphanumerics. It seems to be using the usual ProductID.

                          The (untested) JavaScript should convert a productID into the encodedproductanchor.
                          Code:
                          function makeanchor(id){
                          	var anc = 'a' + escape(id).replace('%', '_');					// escape most characters
                          	var pairs = ['*','2a','@','40','-','5f','+','2b','.','2e','/','2f'];		// pairs of chars and codes omitted by escape
                          	for(i=0; i<pairs.length; i+=2)anc=anc.replace(pairs[i], '_' + pairs[i+1]);	// manually replace these
                          	return anc;
                          }
                          
                          alert(makeanchor('5!1234-567'));
                          Norman - www.drillpine.biz
                          Edinburgh, U K / Bitez, Turkey

                          Comment


                            #14
                            Originally posted by NormanRouxel View Post

                            What's wrong is that the RTS code is not creating a corresponding _nn sequence for all non alphanumerics. It seems to be using the usual ProductID.
                            That incorrect reference is coming from the Perl scripts when you click on the add to cart button as there is insufficient stock to meet the order the perl scripts returns the anchor as part of the url e.g. http://www.jeans-direct.com/cgi-bin/...W16RQE11A-3030.

                            So to solve the problem either the perl needs to be altered or the anchor point generated in the code needs to be altered to meet the anchor in the url.

                            Malcolm

                            SellerDeck Accredited Partner,
                            SellerDeck 2016 Extensions, and
                            Custom Packages

                            Comment


                              #15
                              So to solve the problem either the perl needs to be altered or the anchor point generated in the code needs to be altered to meet the anchor in the url.
                              Agreed. Except that it's the Perl that needs fixing as the anchor in the product layout is correct and changing that would break other bits of Actinic
                              Norman - www.drillpine.biz
                              Edinburgh, U K / Bitez, Turkey

                              Comment

                              Working...
                              X