Loading ...
Sorry, an error occurred while loading the content.

document.write can be a form of eval.

Expand Messages
  • halukakin
    Hi, I just checked the following small line of code with jslint: document.write( hello ); And I got this error : document.write can be a form of eval. I
    Message 1 of 2 , Dec 24, 2008
    • 0 Attachment
      Hi,

      I just checked the following small line of code with jslint:

      document.write('hello');

      And I got this error : "document.write can be a form of eval."


      I would be glad if someone could guide me to information about this error.


      Thanks,

      Haluk
    • Douglas Crockford
      ... error. eval comes in several forms, and is usually to be avoided. document.write is the worst of them. If you wish to ignore this advice, check the
      Message 2 of 2 , Dec 24, 2008
      • 0 Attachment
        --- In jslint_com@yahoogroups.com, "halukakin" <halukakin@...> wrote:
        > I just checked the following small line of code with jslint:
        >
        > document.write('hello');
        >
        > And I got this error : "document.write can be a form of eval."
        >
        > I would be glad if someone could guide me to information about this
        error.

        eval comes in several forms, and is usually to be avoided.
        document.write is the worst of them.

        If you wish to ignore this advice, check the Tolerate eval option.
      Your message has been successfully submitted and would be delivered to recipients shortly.