Announcement

Collapse
No announcement yet.

Require 1 of 2 groups of attributes to be selected

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

    Require 1 of 2 groups of attributes to be selected

    I am working on a Miva site for a client. The original requirement was that an attribute from group one be selected. They would like to to change this to have an attribute from group one or group two be selected but not necessarily one from both groups selected. The user can be allowed to select an attribute from group one and group two so I cannot just add the new option the the existing attribute.
    Is there a way to handle this with the Attributes in Miva?
    Thanks in advance for any assistance!

    Tony

    #2
    I'm thinking the only way to do this would be to use javascript/jQuery ensure that one OR the other attribute drop-downs have a selection. In miva, both attributes would be set to NOT required.
    Bruce Golub
    Phosphor Media - "Your Success is our Business"

    Improve Your Customer Service | Get MORE Customers | Edit CSS/Javascript/HTML Easily | Make Your Site Faster | Get Indexed by Google | Free Modules | Follow Us on Facebook
    phosphormedia.com

    Comment


      #3
      Depending on the details, it may be possible to use inventory variants, so that the store will do the attribute-switching for you. If not, then as Bruce says, you can use Javascript to make some attributes invisible. I'm doing a project like that right now.
      Kent Multer
      Magic Metal Productions
      http://TheMagicM.com
      * Web developer/designer
      * E-commerce and Miva
      * Author, The Official Miva Web Scripting Book -- available on-line:
      http://www.amazon.com/exec/obidos/IS...icmetalproducA

      Comment


        #4
        I'm wondering if the easiest solution might fit the bill? Make the attribute "required" for each group instead. The makes a requirement for a positive selection in each group. Make the default option indicate its not being selected for the order. An example could be:

        Gift Wrap (attribute)

        - NONE (Default Option)
        - Foil
        - Birthday
        - Holiday

        Ribbon (attribute)

        - NONE (Default Option)
        - Bowe
        - String

        If it's more complicated than that, some js/jquery that polls the CGI vars or data-attributes is likely the programming you'll need.

        Scott
        Need to offer Shipping Insurance?
        Interactive Design Solutions https://www.myids.net
        MivaMerchant Business Partner | Certified MivaMerchant Web Developer
        Competitive Rates, Custom Modules and Integrations, Store Integration
        AutoBaskets|Advanced Waitlist Integration|Ask about Shipping Insurance Integration
        My T-shirt Collection is mostly MivaCon T-shirts!!

        Comment


          #5
          Originally posted by ids View Post
          I'm wondering if the easiest solution might fit the bill? Make the attribute "required" for each group instead. The makes a requirement for a positive selection in each group. Make the default option indicate its not being selected for the order. An example could be:

          ...

          Scott
          I think the problem with that is you could leave the default 'no thanks' option selected for both attributes and i believe he wants to have customers select one option from "either" selects.

          Bruce Golub
          Phosphor Media - "Your Success is our Business"

          Improve Your Customer Service | Get MORE Customers | Edit CSS/Javascript/HTML Easily | Make Your Site Faster | Get Indexed by Google | Free Modules | Follow Us on Facebook
          phosphormedia.com

          Comment


            #6
            That would mean it's more complicated. I tried not to assume it was more complicated.

            After reading, I wasn't sure what the requirements actually are and we don't know what the attr/option scenario is.

            But it may be possible to configure so that there is no default selection -- which forces the customer to select an option in either group.
            Last edited by ids; 09-09-19, 02:20 PM.
            Need to offer Shipping Insurance?
            Interactive Design Solutions https://www.myids.net
            MivaMerchant Business Partner | Certified MivaMerchant Web Developer
            Competitive Rates, Custom Modules and Integrations, Store Integration
            AutoBaskets|Advanced Waitlist Integration|Ask about Shipping Insurance Integration
            My T-shirt Collection is mostly MivaCon T-shirts!!

            Comment


              #7
              Thank you for the feedback. I am going to try the javascript/jQuery route.

              Comment

              Working...
              X