Page 10 of 12 FirstFirst ... 89101112 LastLast
Results 91 to 100 of 119
  1. #91
    Join Date
    Jul 2012
    Posts
    16,799
    Plugin Contributions
    17

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    Quote Originally Posted by mattys View Post
    i am using SBA Version 1.5.4 for Zen Cart Version 1.5.4, but on zencart 1.5.3

    is working, but with a few niggles

    one of them being the sort order of colours, e.g. https://www.jarbon.com/alpaca-socks/...-country-socks, if you first select shoe size you will then see the colour options, these are in the incorrect order, as set in attributes controller

    SBA is setting the sort order by attribute value ID, lowest first:

    <select name="id[3]" onchange="i3(this.form);">
    <option value="0" selected="selected">Next select colour</option>
    <option value="18">Black </option><option value="21">dark green </option><option value="272">Red </option><option value="367">damson </option><option value="370">natural white </option></select>

    this is overriding the order i set in attributes controller

    i tried using the sort order you get when adding stock, but this didnt work

    any ideas how this might be fixed?
    Looked at site... Order of attributes was different than described above and appeared to match the sequence of the items in the javascript as expected. What was done to resolve your issue? I wasn't able to reproduce it.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  2. #92
    Join Date
    Sep 2006
    Location
    North Devon, England, UK
    Posts
    289
    Plugin Contributions
    0

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    This is how they are ordered:

    <select name="id[3]" onchange="i3(this.form);">
    <option value="0" selected="selected">Next select colour</option>
    <option value="18">Black </option>
    <option value="21">dark green </option>
    <option value="272">Red </option>
    <option value="367">damson </option>
    <option value="370">natural white </option>
    </select>

    as you can see, ordered numerically by attribute option value

    they should be ordered as per:
    Click image for larger version. 

Name:	attributes-sort-order-1.jpg 
Views:	22 
Size:	27.5 KB 
ID:	15753

  3. #93
    Join Date
    Jul 2012
    Posts
    16,799
    Plugin Contributions
    17

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    That's the sequence my browser presents and how I see it... Sorry can't take a screen capture... Try a dfferent browser or something, as the issue makes little sense unless they were originally filtered in that order, the page loaded, the order changed, and the page "reloaded"... When dealing with attributes, not clearing the cache/session can cause changes to not appear.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  4. #94
    Join Date
    Sep 2006
    Location
    North Devon, England, UK
    Posts
    289
    Plugin Contributions
    0

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    Here are 3 screen grabs, one for firefox, one for ie, one for chrome, all the incorrect order:

    Chrome
    Click image for larger version. 

Name:	chrome-1.jpg 
Views:	23 
Size:	51.0 KB 
ID:	15754

    firefox
    Click image for larger version. 

Name:	firefox-1.jpg 
Views:	26 
Size:	46.1 KB 
ID:	15755

    internet explorer
    Click image for larger version. 

Name:	ie-1.jpg 
Views:	29 
Size:	51.7 KB 
ID:	15756

    they all list the colours numerically, which is incorrect:

    Black
    dark green
    Red
    damson
    natural white

    i would like them to be ordered as i have set them up in attributes controller:

    natural white
    Black
    damson
    Red
    dark green

    Click image for larger version. 

Name:	attributes-sort-order-1.jpg 
Views:	21 
Size:	27.5 KB 
ID:	15757

    P.S.
    The client also sees the incorrect order, so, not just me.

  5. #95
    Join Date
    Jul 2012
    Posts
    16,799
    Plugin Contributions
    17

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    Here is the source code that I see whch produces the desired order as expected:

    Code:
    <tr><td align="right" class="main"><b>colour:</b></td><td class="main"><select name="id[3]" onchange="i3(this.form);">
      <option value="0" selected="selected">Next select colour</option>
    </select>
    </td></tr>
    <tr><td>&nbsp;</td><td><span id="oosmsg" class="errorBox"></span>
    <tr><td colspan="2">&nbsp;
    <script type="text/javascript" language="javascript"><!--
      var stk={1:{370:1,18:1,367:1,272:1,21:1},2:{370:1,18:1,367:1,272:1,21:1},3:{370:1,18:1,367:1,272:1,21:1}};
      var stk2={1:{370:1,18:1,367:1,272:1,21:1},2:{370:1,18:1,367:1,272:1,21:1},3:{370:1,18:1,367:1,272:1,21:1}};
      var txt3={370:'natural white ',18:'Black ',367:'damson ',272:'Red ',21:'dark green '};
      function i1(frm) {
        var displayshown = false;
        var span=document.getElementById("oosmsg");
        while (span.childNodes[0]) {
          span.removeChild(span.childNodes[0]);
        }
        frm['id[3]'].length=1;
        for (opt in stk[frm['id[1]'].value]) {
          if (typeof stk2[frm['id[1]'].value] != "undefined") {
            if (typeof stk2[frm['id[1]'].value][opt] != "undefined") {
              frm['id[3]'].options[frm['id[3]'].length]=new Option(txt3[opt],opt);
            } else {
              frm['id[3]'].options[frm['id[3]'].length]=new Option(txt3[opt] + '- Unavailable ',opt);
            }
          } else {
            frm['id[3]'].options[frm['id[3]'].length]=new Option(txt3[opt] + '- Unavailable ',opt);
            if (displayshown != true) {
              alert('All selections of the attributes below this one are Out of Stock. Please select a different option.');
              stkmsg(frm);
              displayshown=true;
            }
          }
        }
    The mportant part being the sequence ofthe sub groups of stk.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  6. #96
    Join Date
    Jul 2012
    Posts
    16,799
    Plugin Contributions
    17

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    Also, may want to correct the validation issues with that page (and likely other product pages).

    Further, may want to try turning off the Dynamic Dropdown part and see if the same result or different. May have sme sort of Javascript conflict not appearing on my device.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  7. #97
    Join Date
    Sep 2006
    Location
    North Devon, England, UK
    Posts
    289
    Plugin Contributions
    0

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    I can see that the code looks like it should be working, but it would be great if you could provide a screen grab of it working as a drop down, can you sort this please?

    the javascript code above appears after the drop downs, i wander whether this is why the sort order isnt working??

  8. #98
    Join Date
    Sep 2006
    Location
    North Devon, England, UK
    Posts
    289
    Plugin Contributions
    0

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    Quote Originally Posted by mc12345678 View Post
    Also, may want to correct the validation issues with that page (and likely other product pages).

    Further, may want to try turning off the Dynamic Dropdown part and see if the same result or different. May have sme sort of Javascript conflict not appearing on my device.
    ok, i'll try this

    thanks

  9. #99
    Join Date
    Sep 2006
    Location
    North Devon, England, UK
    Posts
    289
    Plugin Contributions
    0

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    i plumped for deactivating dynamic drop downs, all seems to be working now

    matt

  10. #100
    Join Date
    Sep 2006
    Location
    North Devon, England, UK
    Posts
    289
    Plugin Contributions
    0

    Default Re: "Stock by Attributes" (version 1.5.3). This MOD is ONLY for Zen Cart 1.5.1 ..whad

    actually, deactivating dynamic drop down creates to many issues, so am reactivating, will investigate why javascript order not being displayed

    matt

 

 
Page 10 of 12 FirstFirst ... 89101112 LastLast

Similar Threads

  1. v151 USPS module version for RateV4, Zen Cart 1.5? / "Online Rate" vs. "Post Office Price"
    By CarolineBogart in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 10 Dec 2012, 03:36 AM
  2. Comment out "Check for Updates" Button, "Support Site" Link, & "Version" Link?
    By g00glethis1 in forum Customization from the Admin
    Replies: 4
    Last Post: 15 Mar 2010, 06:32 AM
  3. Show "Units In Stock" for certain product only.
    By laydiefa in forum Templates, Stylesheets, Page Layout
    Replies: 5
    Last Post: 26 Nov 2008, 08:08 PM
  4. Replies: 2
    Last Post: 8 Jun 2008, 07:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR