Announcement

Collapse
No announcement yet.

Permutation Choice ID List

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

    Permutation Choice ID List

    In a drop down list the <option value=""> returns a incrementing value depending on its location in the list.

    How / where is the value="" drawing the actual content of the selection from? I assume there is an array holding the info.

    Looking to output the chosen selection back to the page via getElementbyId

    v9.0.2


    Bikster
    SellerDeck Designs and Responsive Themes

    #2
    Hi Jont,

    Sorry for not responding to this sooner. I'm not sure that I've understood completely what you are asking for but are you wanting to know where it gets the ListIndex from?
    ********************
    Tracey
    SellerDeck

    Comment


      #3
      It goes like this I think (as far as I've worked it out).

      You have

      <option value="<actinic:variable name="PermutationChoiceList" value="Permutation Choice ID List" />">

      Now that Permutation Choice ID List is a layout but contains just the single line

      <actinic:variable name="PermutationChoice" value="Permutation Choice ID" />

      Now this is an atomic Actinic variable but with a special qualification. Because it's part of a list, it's not a single value but one of an array, you get a value that's indexed by whatever that items internal Listindex is. In this case, this type of list doesn't have it's own ListIndex but inherits it from the calling layout (in this case PermutationChoiceList which in turn gets it's value from Permutation Row).
      Norman - www.drillpine.biz
      Edinburgh, U K / Bitez, Turkey

      Comment


        #4
        Looking to output the chosen selection back to the page via getElementbyId
        It's a lot safer to attach an ID to the SELECT tag.

        Then use

        var sel = document.getElementById('selectid');
        var value = sel.options[sel.selectedIndex];
        Norman - www.drillpine.biz
        Edinburgh, U K / Bitez, Turkey

        Comment


          #5
          Cheers Norman. I have it working with a manual array so will look at drawing the info from the Actinic array. (my getElementbyId in the first post was to put the code back via innerHTML to a different part of the page)

          Not having it's own ListIndex is proving troublesome for inserting a block if into the <option> ... another task not related to the above. Will look at integrating your code to provide a bridge in what I have already.


          Bikster
          SellerDeck Designs and Responsive Themes

          Comment

          Working...
          X