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

Bad HTML string?

Expand Messages
  • Jakob Kruse
    Hi If I run the following code (properly indented) through JSLint at jslint.com with all options cleared, it validates. If I run the exact same code through
    Message 1 of 2 , Feb 3, 2012
    • 0 Attachment
      Hi

      If I run the following code (properly indented) through JSLint at jslint.com with all options cleared, it validates. If I run the exact same code through JSLint locally, with no options, using jslint.js downloaded today from jslint.com, it errors with “Bad HTML string”.

      /*jslint sloppy: true */
      function quote(s) {
      return '"' + s + '"';
      }

      Any ideas as to the difference?

      /Jakob

      [Non-text portions of this message have been removed]
    • Merlin
      ... I ve tried linting the file t.js on both the full and minimized versions of jslint in Widget Tester. I m not seeing the fault in either version. Using file
      Message 2 of 2 , Feb 3, 2012
      • 0 Attachment
        --- In jslint_com@yahoogroups.com, "Jakob Kruse" <kruse@...> wrote:
        > If I run the following code (properly indented) through JSLint at jslint.com with all options cleared, it validates. If I run the exact same code through JSLint locally, with no options, using jslint.js downloaded today from jslint.com, it errors with "Bad HTML string".
        >
        > /*jslint sloppy: true */
        > function quote(s) {
        > return '"' + s + '"';
        > }
        >
        > Any ideas as to the difference?

        I've tried linting the file t.js on both the full and minimized versions of jslint
        in Widget Tester. I'm not seeing the fault in either version.

        Using file from http://jslint.com/jslint.js:

        Welcome to Yahoo! Widgets 4.5.2x10A50 on 02/03/12 11:26:46.066
        getJSLint:Using local JSLint file. MD5 sum: 1467142763141787501a2c3f745d303f
        Widget Tester 9.4.4
        JSLint by Douglas Crockford, Edition 2012-01-26.
        Filename: t.js
        ok

        Using file from http://www.JSLint.com/minjslint.js:

        Welcome to Yahoo! Widgets 4.5.2x10A50 on 02/03/12 11:28:07.856
        getJSLint:Using today's JSLint file. MD5 sum: 73152b10706369d0c7dbea86751e12c6
        Widget Tester 9.4.4
        JSLint by Douglas Crockford, Edition 2012-01-26.
        Filename: t.js
        ok

        t.js:
        /*jslint sloppy: true */
        function quote(s) {
        return '"' + s + '"';
        }

        (Tried it with a tab and with four spaces.)

        Harry.
      Your message has been successfully submitted and would be delivered to recipients shortly.