Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Code Errors

Contributor ,
Dec 12, 2017 Dec 12, 2017

All

I got the three code error messages shown on the screenshot. What do the first two mean? The third one is strange as I have a <td> start tag as well as the </td> end tag.

Thanks

Alan

BTW Why do I only get three error messages in DW, yet using WC3 Validator I get 153

Screen Shot 2017-12-12 at 9.10.24 AM.png

1.0K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Dec 12, 2017 Dec 12, 2017

English100, the second " for your style attribute needed to stay there, just place a space between " and height.

<td style="border: 2px solid #000A00;" height="25" colspan="3" align="left" bgcolor="#99CC66">

                                                                                     ^^^

BTW.. align="left" has been deprecated; you'd be better off adding that to your style.

<td style="border: 2px solid #000A00; text-align: left;" height="25" colspan="3" bgcolor="#99CC66">

HTH,

^ _ ^

UPDATE:  Act

...
Translate
LEGEND ,
Dec 12, 2017 Dec 12, 2017

We'd have to see the actual code before anyone can help with this.

V/r,

^ _ ^

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 12, 2017 Dec 12, 2017

Usually, when you see "Special characters must be escaped: [ > ]" it means you've done one of a couple things...

1. Possibly used a < or > in your html text rather than the correct html entity of &lt; or &gt;.
2. It can also mean you've got two << or >> somewhere that you're only supposed to have 1.
3. You're missing a < or > and the parser is reading two tags as one with an extra bracket

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Dec 12, 2017 Dec 12, 2017

Jon

Here is the code that the first two errors are referring to and I don't see any problems with lines 47 and 48.

Alan

Screen Shot 2017-12-12 at 11.25.55 AM.png

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Dec 12, 2017 Dec 12, 2017

Is this straight HTML, or something like ColdFusion?

If it's ColdFusion, and the line in question is between <cfoutput> and </cfoutput> tags, then the hashtag for your color needs to be escaped (##).

Otherwise, there is no space between the last quotes of your style attribute and the height attribute.

HTH,

^ _ ^

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Dec 12, 2017 Dec 12, 2017

WolfShade

It's straightforward HTML. I put the space as mentioned between the ; after the color and the 'h' of height and removed the " before height but the errors don't go away.

Alan

Screen Shot 2017-12-12 at 1.51.39 PM.png

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Dec 12, 2017 Dec 12, 2017

English100  wrote

WolfShade

It's straightforward HTML. I put the space as mentioned between the ; after the color and the 'h' of height and removed the " before height but the errors don't go away.

Alan

Screen Shot 2017-12-12 at 1.51.39 PM.png

As Jon said -  very often its NOT the lines that are indicated where the mistake lies. If you post some more of the code maybe someone could identify which line/s of code is/are the culprit....

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Dec 12, 2017 Dec 12, 2017
LATEST

English100, the second " for your style attribute needed to stay there, just place a space between " and height.

<td style="border: 2px solid #000A00;" height="25" colspan="3" align="left" bgcolor="#99CC66">

                                                                                     ^^^

BTW.. align="left" has been deprecated; you'd be better off adding that to your style.

<td style="border: 2px solid #000A00; text-align: left;" height="25" colspan="3" bgcolor="#99CC66">

HTH,

^ _ ^

UPDATE:  Actually, now that I think about it, you should also add height and background-color to your style - CSS is the present and future of HTML

<td style="border: 2px solid #000A00; text-align: left; height: 25px; background-color: #99CC66;" colspan="3">

BTW.. the background-color you are using can also be done in shorthand:  #9C6;

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 12, 2017 Dec 12, 2017

The other, truly fun part about that error: it almost never shows on the line with the actual problem.

Could you post the entire code to the forum (just copy and paste out of DW, no need for images).

Just don't try it with email, the code won't come through.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Dec 12, 2017 Dec 12, 2017

English100  wrote

All

I got the three code error messages shown on the screenshot. What do the first two mean? The third one is strange as I have a <td> start tag as well as the </td> end tag.

Thanks

Alan

BTW Why do I only get three error messages in DW, yet using WC3 Validator I get 153

Screen Shot 2017-12-12 at 9.10.24 AM.png

I'd be more concerned with the 153 error/warning messages that you get if you validate directly via the WC3 validation service. I cant think of a single web-application out there that is any good at validation and mostly I have no idea what they use to validate against. One thing for sure though, don't treat 'inhouse' validation seriously, treat it as a heads-up. The only validation service that is any good is the online validation service, not somecrack-pot interpretation of the online validation service.

Not so long ago really good editors were taking your page and 'uploading' it to the online validation service which  threw back an exact same copy of what you could see if you validated directly through the WC3 site. Now days It seems to be a rough interpretation and a bit of this and a bit of the other thrown in.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 12, 2017 Dec 12, 2017

The actual validation tool in DW under File > Validate > Current Document (W3C) or Window > Results > Validation uses the correct online W3C validator at http://validator.w3.org/nu.

However, the Output window in the screen grab will show whatever the Linter decides to mark as errors, based on whoever came up with half of the "errors" it lists, and what the user sets in the Preferences.

@English100,

Osgood is right, don't trust the Output window. If you're running your page through the validator, either through the program or at the site, and it says you have 153 errors, that would be the accurate result.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines