IDMIntranet eXchange 
[ Home | Post | Register/Awards | Find | F A Q | Archive ]

 Home/Articles
  •  Recent Tutorials
  •  Recent Features
  •  Top Twenty Articles
  •  Oldies But Goodies
 ITAdvisor
  •  News & Analysis
  •  Security
  •  Intranet Buzz!
  •  Intranet Talk
  •  Intranet Corner
  •  CaseStudies/ Departments
 Intranet Development
  •  WirelessEnterprise
  •  Getting Started
  •  JavaScript
  •  VBScript
  •  HTML/DHTML
  •  XML
  •  ASP/IIS
  •  Perl
  •  PHP
  •  CascadingStyleSheets
  •  Dreamweaver
  •  FrontPage
 Information Management
  •  Content Management
  •  Collaboration
  •  Portals
  •  ASPs
 Intranet Resources
  •  Intranet FAQ
  •  Discussion Board
  •  Jobs Board
  •  Events Calendar
  •  Intranet Books
  •  Tools of the Trade
  •  Glossary
 Archive
 Site Map

Modern Daze: Comics Page

New

Free Newsletter!
 
Privacy Policy

Search IDM:


Hot Intranet eXchange discussion board Threads
º  masking in javascript
º  Can pseudo-url in image maps work? -
º  How do I make these into a real type?
º  Access and Intranet
º  Help with a plan for an Intranet
º  Frames problem
º  Opening Word and Excel Documents from Intranet
º  asp file not running in local intranet environment
º  Best Document Management / Collaboration software
º  readonly text entry
º  Small company intranets
º  Forcing IE to open Excel Workbooks in a New Instance
º  Criteria for content management systems/products
º  Best Document Management / Collaboration software
º  How to have How to have an image follow the mouse cursor
º  Creating Hyperlinks - Database driven
º  Table background..
º  MS Access returning multiple rows

More Intranet eXchange Highlights

*  Articles Elswhere on Internet.com

Re: How do I make these into a real type?


[ Follow Ups ] [ Post Followup ] [ Intranet eXchange ] [ IDM Home ]


Posted by Chris Davies on August 25, 2000 at 7:6:6:

In Reply to: Re: How do I make these into a real type? posted by Jon Hanlon on August 24, 2000 at 19:30:36:

Thanx....
Your type checking routine doesn't work, but I have one of my own which i'm already using. besides which using parseFloat on an alpha type is not a fatal error.

<SCRIPT LANGUAGE="JavaScript">

<!-- Begin
function validate(field) {
var valid = "0123456789"
var ok = "yes";
var temp;
for (var i=0; i<field.value.length; i++) {
temp = "" + field.value.substring(i, i+1);
if (valid.indexOf(temp) == "-1") ok = "no";
}
if (ok == "no") {
alert("Invalid entry! numbers are accepted!");
field.focus();
field.select();
}
}
// End -->
</script>
this is a script that checks a field to ensure it has only numbers, although you could add other chars....



Follow Ups:



Post a Followup

Name:     
E-Mail:   
Subject:  
Message:

Optional Link URL: 
Link Title:        

      



[ Follow Ups ] [ Post Followup ] [ Intranet eXchange ] [ IDM Home ]