ie6 javascript js 缺少标识符总结(转载)

转载http://blog.csdn.net/qingyundys/article/details/6218280

ie6 javascript js 缺少标识符总结


1. ie6下,javascript代码中,不能出现保留字符。解决办法就是避免直接使用JS的保留字符。


2.
IE和Firefox不兼容的地方.属性之间是要用","分隔的,但最后一个属性的后面在IE中是不能有的,firefox可有可无.
至于最后的";"是另外一回事了.这是Javascript的语法问题.如果后面没有其它js语句时";"可以省略.

附:JavaScript的保留字

 

  1. abstract

  2. boolean  break  byte

  3. case  catch  char  class  const  continue

  4. default  do  double

  5. else  extends

  6. false  final  finally  float  for  function

  7. goto

  8. if  implements  import  in  instanceof  int  interface

  9. long

  10. native  new  null

  11. package  private  protected  public

  12. return

  13. short  static  super  switch  synchronized

  14. this  throw  throws  transient  true  try

  15. var  void

  16. while  with

posted @ 2014-10-26 10:27  焦涛  阅读(360)  评论(0)    收藏  举报