Results 1 to 4 of 4

Thread: Forms

  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Newark, New Jersey, USA
    Posts
    999
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Forms

    Hullo ladies... here's my grief... I'm trying to create a form, with a bunch of check boxes. What I want are some predefined box that if I check one of them, a bunch of other check boxes auto check.... [img]/forums/images/smilies/smile.gif[/img]
    Mike Wolfman
    Jack of all, Master of none
    Bow before me, for I am root.
    <IMG SRC=http://www.wopr.com/w3tfiles/112673-wolfsig.jpg>

  2. #2
    Platinum Lounger
    Join Date
    Dec 2000
    Location
    Queanbeyan, New South Wales, Australia
    Posts
    3,730
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Forms

    Mike,

    I'm not ladies. Forgive me for intruding.

    I assume that vwhat you want is the same as Hotmail. If I click in the option box which is the header, all boxes underneath that on the list are selected.

    If that's the case, here's the code from Hotmail:

    <pre>function CheckCheckAll()
    {
    var TotalBoxes = 0;
    var TotalOn = 0;
    for (var i=0;i<document.hotmail.elements.length;i++)
    {
    var e = document.hotmail.elements[i];
    if ((e.name != 'allbox') && (e.type=='checkbox'))
    {
    TotalBoxes++;
    if (e.checked)
    {
    TotalOn++;
    }
    }
    }
    if (TotalBoxes==TotalOn)
    {document.hotmail.allbox.checked=true;}
    else
    {document.hotmail.allbox.checked=false;}
    }
    </pre>

    Subway Belconnen- home of the Signboard to make you smile. Get (almost) daily updates- follow SubwayBelconnen on Twitter.

  3. #3
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Newark, New Jersey, USA
    Posts
    999
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Forms

    Heya Geoff,

    I need one that only selects certain boxes.... not all of them
    Mike Wolfman
    Jack of all, Master of none
    Bow before me, for I am root.
    <IMG SRC=http://www.wopr.com/w3tfiles/112673-wolfsig.jpg>

  4. #4
    Plutonium Lounger Leif's Avatar
    Join Date
    Dec 2000
    Location
    U.K.
    Posts
    14,010
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Forms

    Does the code <A target="_blank" HREF=http://javascript.internet.com/forms/controlled-boxes.html>here</A> give you any clues?
    I don't know enough to guide you further - maybe 'cos I'm not a lady either <img src=/S/laugh.gif border=0 alt=laugh width=15 height=15> .

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •