Results 1 to 3 of 3

Thread: What am I Missing

  1. #1
    Join Date
    Apr 2007
    Location
    Southwest France
    Posts
    29
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default What am I Missing

    Apart from the usual "sandwich short of a picnic" comment have a look at this code,
    what I'm trying to achieve.

    Is 3 columns of numbered buttons, the output of each column to be displayed at the bottom of the relevant column and independent of the other two.

    for example pushing buttons in column two shouldn't delete or change column one and three output.

    Hope this makes sense

    I've (well with the help of some of the chaps on the forum) managed to get this far,
    I've got it working in frames (one frame for each column of numbers)
    but that don't fit in will what I'm doing, so it's all got to be on one page.

    Sorry if there is some bad coding I've been trying all sorts, but still no results.

    The Code:
    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
        "http://www.w3.org/TR/html4/loose.dtd">
    
    <html>
    <head>
    <title></title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    
    <script type="text/javascript">
    
    function showNumber(Thousum) {
    obj = document.getElementById('milles').innerHTML=Thousum;
    }
    function showNumber(hundsum) {
    obj = document.getElementById('cents').innerHTML=hundsum;
    }
    </script>
    </head>
    <body BGCOLOR="#CC9900">
    <div style="position:absolute; left:80px; top:5px; width:100px; height:285px;">
    <center><fieldset style="width:100px; height:285px;background-color: Black">
    <Font size="3" color="Yellow"><Legend><b><u>Thousands</u></b></Legend></Font>
    <form action="" name="Thousum">
    <input name="Thousands" type="button" onclick="showNumber('Thousands');" value="000s"><br>
    <input name="Thousands" type="button" onclick="showNumber('one Thousand');" value="1000"><br>
    <input name="Thousands" type="button" onclick="showNumber('two Thousand');" value="2000"><br>
    <input name="Thousands" type="button" onclick="showNumber('three Thousand');" value="3000"><br>
    <input name="Thousands" type="button" onclick="showNumber('four Thousand');" value="4000"><br>
    <input name="Thousands" type="button" onclick="showNumber('five Thousand');" value="5000"><br>
    <input name="Thousands" type="button" onclick="showNumber('six Thousand');" value="6000"><br>
    <input name="Thousands" type="button" onclick="showNumber('seven Thousand');" value="7000"><br>
    <input name="Thousands" type="button" onclick="showNumber('eight Thousand');" value="8000"><br>
    <input name="Thousands" type="button" onclick="showNumber('nine Thousand');" value="9000">
    </Fieldset>
    <input name="Clear" type="button" onclick="showNumber('');" value="Clear" style="background: Red; font-weight: bolder; color: White"><br>
    </div>
    </center>
    
    
    <div style="position:absolute; left:62px; top:365px; width:140px; z-index:2">
    <h3 id="milles" align="right"></h3>
    </form>
    </div>
    
    <div style="position:absolute; left:280px; top:5px; width:100px; height:285px;">
    <center><fieldset style="width:100px; height:285px;background-color: Black">
    <Font size="3" color="Yellow"><Legend><b><u>Thousands</u></b></Legend></Font>
    <form action="" name="hundsum">
    <input name="sands" type="button" onclick="showNumber('Thousands');" value="000s"><br>
    <input name="sands" type="button" onclick="showNumber('une mille');" value="1000"><br>
    <input name="sands" type="button" onclick="showNumber('deux milles');" value="2000"><br>
    <input name="sands" type="button" onclick="showNumber('trois milles');" value="3000"><br>
    <input name="sands" type="button" onclick="showNumber('quatre milles');" value="4000"><br>
    <input name="sands" type="button" onclick="showNumber('cinq milles');" value="5000"><br>
    <input name="sands" type="button" onclick="showNumber('six milles');" value="6000"><br>
    <input name="sands" type="button" onclick="showNumber('sept milles');" value="7000"><br>
    <input name="sands" type="button" onclick="showNumber('huit milles');" value="8000"><br>
    <input name="sands" type="button" onclick="showNumber('neuf milles');" value="9000">
    </Fieldset>
    <input name="Clear" type="button" onclick="showNumber('');" value="Clear" style="background: Red; font-weight: bolder; color: White"><br>
    </div>
    </center>
    
    
    <div style="position:absolute; left:280px; top:365px; width:140px; z-index:2">
    <h3 id="cents" align="right"></h3>
    </form>
    </div>
    
    
    
    </body>
    </html>

    Many Thanks

    Steve C.

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
        "http://www.w3.org/TR/html4/loose.dtd">
    
    <html>
    <head>
    <title></title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    
    <script type="text/javascript">
    
    function showNumber(Thousum) {
    obj = document.getElementById('milles').innerHTML=Thousum;
    }
    function showNumber1(hundsum) {
    obj = document.getElementById('cents').innerHTML=hundsum;
    }
    </script>
    </head>
    <body BGCOLOR="#CC9900">
    <div style="position:absolute; left:80px; top:5px; width:100px; height:285px;">
    <center><fieldset style="width:100px; height:285px;background-color: Black">
    <Font size="3" color="Yellow"><Legend><b><u>Thousands</u></b></Legend></Font>
    <form action="" name="Thousum">
    <input name="Thousands" type="button" onclick="showNumber('Thousands');" value="000s"><br>
    <input name="Thousands" type="button" onclick="showNumber('one Thousand');" value="1000"><br>
    <input name="Thousands" type="button" onclick="showNumber('two Thousand');" value="2000"><br>
    <input name="Thousands" type="button" onclick="showNumber('three Thousand');" value="3000"><br>
    <input name="Thousands" type="button" onclick="showNumber('four Thousand');" value="4000"><br>
    <input name="Thousands" type="button" onclick="showNumber('five Thousand');" value="5000"><br>
    <input name="Thousands" type="button" onclick="showNumber('six Thousand');" value="6000"><br>
    <input name="Thousands" type="button" onclick="showNumber('seven Thousand');" value="7000"><br>
    <input name="Thousands" type="button" onclick="showNumber('eight Thousand');" value="8000"><br>
    <input name="Thousands" type="button" onclick="showNumber('nine Thousand');" value="9000">
    </Fieldset>
    <input name="Clear" type="button" onclick="showNumber('');" value="Clear" style="background: Red; font-weight: bolder; color: White"><br>
    </div>
    </center>
    
    
    <div style="position:absolute; left:62px; top:365px; width:140px; z-index:2">
    <h3 id="milles" align="right"></h3>
    </form>
    </div>
    
    <div style="position:absolute; left:280px; top:5px; width:100px; height:285px;">
    <center><fieldset style="width:100px; height:285px;background-color: Black">
    <Font size="3" color="Yellow"><Legend><b><u>Thousands</u></b></Legend></Font>
    <form action="" name="hundsum">
    <input name="sands" type="button" onclick="showNumber1('Thousands');" value="000s"><br>
    <input name="sands" type="button" onclick="showNumber1('une mille');" value="1000"><br>
    <input name="sands" type="button" onclick="showNumber1('deux milles');" value="2000"><br>
    <input name="sands" type="button" onclick="showNumber1('trois milles');" value="3000"><br>
    <input name="sands" type="button" onclick="showNumber1('quatre milles');" value="4000"><br>
    <input name="sands" type="button" onclick="showNumber1('cinq milles');" value="5000"><br>
    <input name="sands" type="button" onclick="showNumber1('six milles');" value="6000"><br>
    <input name="sands" type="button" onclick="showNumber1('sept milles');" value="7000"><br>
    <input name="sands" type="button" onclick="showNumber1('huit milles');" value="8000"><br>
    <input name="sands" type="button" onclick="showNumber1('neuf milles');" value="9000">
    </Fieldset>
    <input name="Clear" type="button" onclick="showNumber1('');" value="Clear" style="background: Red; font-weight: bolder; color: White"><br>
    </div>
    </center>
    
    
    <div style="position:absolute; left:280px; top:365px; width:140px; z-index:2">
    <h3 id="cents" align="right"></h3>
    </form>
    </div>
    
    
    
    </body>
    </html>
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Apr 2007
    Location
    Southwest France
    Posts
    29
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default

    John
    I see where I was going wrong by not numbering the "showNumber1" what a dim bat,
    Anyway lots of thanks to you,

    Best Regards

    Steve C.

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
  •