Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

The JavaScript FAQ
Prev Home Next

Reserved words in JavaScript

Table of ContentsTable of Contents

Question: What reserved words are there in JavaScript?

Answer: Reserved words of the JavaScript langauge are listed below. (Some of these words are actually used in the Java language, and are reserved in JavaScript for compatibility purposes or as possible extensions.) When choosing names for your JavaScript variables, avoid these reseved words!

abstract  else  instanceof  switch  
boolean  enum  int  synchronized  
break  export  interface  this  
byte  extends  long  throw  
case  false  native  throws  
catch  final  new  transient  
char  finally  null  true  
class  float  package  try  
const  for  private  typeof  
continue  function  protected  var  
debugger  goto  public  void  
default  if  return  volatile  
delete  implements  short  while  
do  import  static  with  
double  in  super    

In addition to the above reserved words, you'd better avoid the following identifiers as names of JavaScript variables. These are names of client-side objects, methods, or properties in Netscape Navigator or Internet Explorer:

alert  hidden  outerWidth  
all  history  packages  
anchor  image  pageXOffset  
anchors  images  pageYOffset  
area  isNaN  parent  
array  java  parseFloat  
assign  JavaArray  parseInt  
blur  JavaClass  password  
button  JavaObject  pkcs11  
checkbox  JavaPackage  plugin  
clearTimeout  innerHeight  prompt  
clientInformation  innerWidth  prototype  
close  layer  radio  
closed  layers  reset  
confirm  length  screenX  
crypto  link  screenY  
date  location  scroll  
defaultStatus  Math  secure  
document  mimeTypes  select  
element  name  self  
elements  navigate  setTimeout  
embed  navigator  status  
embeds  netscape  String  
escape  Number  submit  
eval  Object  sun  
event  offscreenBuffering  taint  
fileUpload  onblur  text  
focus  onerror  textarea  
form  onfocus  top  
forms  onload  toString  
frame  onunload  unescape  
frames  open  untaint  
frameRate  opener  valueOf  
function  option  window  
getClass  outerHeight    

JavaScripter.net. Copyright © 1999-2006, Alexei Kourbatov

The JavaScript FAQ
Prev Home Next


 
 
  Mirrored with kind permission of Alexei Kourbatov Design by Interspire