Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    Regular Coder
    Join Date
    May 2009
    Posts
    813
    Thanks
    123
    Thanked 24 Times in 24 Posts

    Map not validating

    Code:
    <img class="border" alt="googtatic_map" 
     src="http://maps.google.com/maps/api/staticmap?center=51.454863,0.011673&zoom=13&markers=United+Reformed+Church,+111+Burnt+Ash+Road,++Lee,+London+SE12+8RG,+UK&size=250x250&sensor=true" />
    I have the above code and it is not validating with the w3c validation for XHTML it has thrown up 8 errors and 14 warnings. Should I ignore them or what? As I do like my code to validate.

  • #2
    Senior Coder Dormilich's Avatar
    Join Date
    Jan 2010
    Location
    Behind the Wall
    Posts
    3,278
    Thanks
    12
    Thanked 342 Times in 338 Posts
    you’re not using XHTML anyway, so it doesn’t really matter. (if you were using XHTML, it would only work if it were valid)
    The computer is always right. The computer is always right. The computer is always right. Take it from someone who has programmed for over ten years: not once has the computational mechanism of the machine malfunctioned.
    André Behrens, NY Times Software Developer

  • #3
    Regular Coder
    Join Date
    May 2009
    Posts
    813
    Thanks
    123
    Thanked 24 Times in 24 Posts

    re

    I am working in XHTML and I did wrap my code in code tags

  • #4
    Senior Coder
    Join Date
    Sep 2010
    Posts
    1,971
    Thanks
    15
    Thanked 229 Times in 229 Posts
    It's very common for 'third party' code like that to not validate, but some library is generally used to covert it into valid code during page load.
    So the browser understands it and it's not generally a big problem.

  • #5
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,436
    Thanks
    75
    Thanked 4,372 Times in 4,337 Posts
    You can get rid of several of the errors/warnings by simply replacing all the & in the URL string with &amp;

    What are the other errors/warnings? Can you show us the page live?
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •