Any1 knows javascript

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Startzone
    Confirmed User
    • Dec 2006
    • 1063

    #1

    Any1 knows javascript

    Hi,

    In the next script:

    I am working on minimal symbols check. If you have only text box it's easy, but i need to figure a way to check text only when Other is selected

    <html>
    <head>
    <title>Bad Link Report</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <link rel="stylesheet" href="style.css" type="text/css">

    <script language="JavaScript">
    <!--
    function enableFld(elementId,tostate){
    eval("document.someform." + elementId + ".disabled="+tostate+";");
    }
    //-->
    </script>

    <script language="javascript" type="text/javascript">
    <!--
    function imposeMaxLength(Object, MaxLen)
    {
    return (Object.value.length <= MaxLen);
    }
    -->
    </script>

    </head>
    <body leftMargin="0" topMargin="0" MARGINHEIGHT="0" MARGINWIDTH="0">

    <br>
    <table align="center" width="202" cellspacing="0" cellpadding="0">
    <tr>
    <td class="black" align="center">
    <table width="200" border="0" cellspacing="0" cellpadding="3">
    <tr>
    <td class="black"><b>Bad Link Report</b></td>
    </tr>
    <tr>
    <td align="left" bgcolor="#BFD8F1">

    Thank you for your time<br>
    Click to report bad link<br><br>

    <form action="/bad.php" method="post" name="someform">
    <input type="hidden" name="id" value="137477">

    <input type="radio" name="op" value="badlink" checked onclick="javascript:enableFld('bao_text','true');" />bad link<br>
    <input type="radio" name="op" value="doublelink" onclick="javascript:enableFld('bao_text','true');" />double link<br>
    <input type="radio" name="op" value="wrongname" onclick="javascript:enableFld('bao_text','true');" />wrong name<br>
    <input type="radio" name="op" value="other" onclick="javascript:enableFld('bao_text','false'); " />Other:<br>
    <textarea name="bao_text" rows="2" cols="20" onkeypress="return imposeMaxLength(this, 15);" disabled="disabled"></textarea><br>

    <input type="submit" name="submit" value="Report" class="button">

    </form>
    <br>
    <tr>
    <td class=black></td>
    </tr>
    </table>
    </td>
    </tr>
    </table>
    </html>


    Any1?

    Thanks!
    Check this...... Gammae.com & DDF Cash & FetishWealth
  • adult-help
    Confirmed User
    • Mar 2008
    • 2450

    #2
    So you want to hide textarea and show it only if Others radio box is selected? Right?
    Adult web templates, Adult WordPress Themes, TGP, MGP..
    also Complete Wordpress PaySite Development - Adult WordPress Blog Themes - Free FHG Templates - Free PaySite Script - Adult Tutorials Directory - Adult Domain Marketplace - Adult Jobs

    Comment

    • Startzone
      Confirmed User
      • Dec 2006
      • 1063

      #3
      Hi,

      No I only want people to have to fill in textarea if the choose "Others" and then minimize the length to 15.

      Thanks!
      Check this...... Gammae.com & DDF Cash & FetishWealth

      Comment

      Working...