1. I've started a massive SPAM purge, any accounts that have spammed are being removed, also for a short period new user signups are disallowed until the SPAM cleaning is finished.

Textbox

Discussion in 'Java Script/AJAX' started by morris, Sep 2, 2007.

Thread Status:
Not open for further replies.
  1. morris

    morris New Member

    Joined:
    Aug 31, 2007
    Messages:
    65
    Likes Received:
    0
    Trophy Points:
    0
    Hey all,
    I was wondering if anyone new how to make a text box except numbers only? Iv tried javascript have only got the following but it does not work properly as letters can be placed after one number is entered.
    var changeToNumberType = parseFloat(document.details.theCost.value);
    var mightBeNumber = isNaN(changeToNumberType);
    if (mightBeNumber==true)
    {
    alert("Sorry! Not a number");
    return(false);
    }

    Any help would be great thanks
    Loading...
Thread Status:
Not open for further replies.

Share This Page