amazon causes html not to validate

Discussion in 'ASP .Net' started by Jeff, Jan 26, 2010.

  1. Jeff

    Jeff Guest

    Hi

    asp.net 3.5

    I've created a site which originally the html validates. Now I've signed up
    to Amazon.com as an affiliate. I selected 2 banners and a widget. These are
    causing my html pages to not validate.

    I'm trying first to solve this problem by myself, but there are a few things
    which is troubling me:
    The script from amazon contains an object tag with a hexe value as player
    id. Inside this object tag there is a embed tag which also has the same
    player id as in object tag... So in visual studio I get a green line under
    both id's saying another object on page is using this id....
    But how come it be wrong, it's made my amazon.com... they should have some
    guys who knows their stuff. So wonder how I should change this

    A lot of the rest of the errors are because of using & in the affiliate
    link. But I don't understand why that's wrong to use &. The validator
    suggests using & instead. Not sure what's best here...

    Below I post the html of such an affiliate link so you better can see what I
    mean:
    <div style="width:336px; margin-left:auto; margin-right:auto;">
    <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
    codebase="http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab"
    id="Player_31808dd6-254b-4a01-a484-3d300cef27c5" width="300px"
    height="250px">
    <param name="movie"
    value="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&MarketPlace=US&ID=V20070822%2FUS%2FAFFILIATEID-20%2F8009%2F31808dd6-254b-4a01-a484-3d300cef27c5&Operation=GetDisplayTemplate">
    <param name="quality" value="high">
    <param name="bgcolor" value="#FFFFFF">
    <param name="allowscriptaccess" value="always">
    <embed
    src="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&MarketPlace=US&ID=V20070822%2FUS%2FAFFILIATEID-20%2F8009%2F31808dd6-254b-4a01-a484-3d300cef27c5&Operation=GetDisplayTemplate"
    id="Player_31808dd6-254b-4a01-a484-3d300cef27c5" quality="high"
    bgcolor="#ffffff" name="Player_31808dd6-254b-4a01-a484-3d300cef27c5"
    allowscriptaccess="always" type="application/x-shockwave-flash"
    align="middle" height="250px" width="300px"></embed>
    </object>
    <noscript><a
    href="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&MarketPlace=US&ID=V20070822%2FUS%2FAFFILIATEID-20%2F8009%2F31808dd6-254b-4a01-a484-3d300cef27c5&Operation=NoScript">Amazon.com
    Widgets</a></noscript>
    </div>

    any suggesions?
     
    Jeff, Jan 26, 2010
    #1
    1. Advertising

  2. On Jan 26, 3:12 pm, "Jeff" <> wrote:
    > Hi
    >
    > asp.net 3.5
    >
    > I've created a site which originally the html validates. Now I've signed up
    > to Amazon.com as an affiliate. I selected 2 banners and a widget. These are
    > causing my html pages to not validate.
    >
    > I'm trying first to solve this problem by myself, but there are a few things
    > which is troubling me:
    > The script from amazon contains an object tag with a hexe value as player
    > id. Inside this object tag there is a embed tag which also has the same
    > player id as in object tag... So in visual studio I get a green line under
    > both id's saying another object on page is using this id....
    > But how come it be wrong, it's made my amazon.com... they should have some
    > guys who knows their stuff. So wonder how I should change this
    >
    > A lot of the rest of the errors are because of using & in the affiliate
    > link. But I don't understand why that's wrong to use &. The validator
    > suggests using &amp; instead. Not sure what's best here...
    >
    > Below I post the html of such an affiliate link so you better can see what I
    > mean:
    > <div style="width:336px; margin-left:auto; margin-right:auto;">
    >   <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
    > codebase="http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab"
    > id="Player_31808dd6-254b-4a01-a484-3d300cef27c5"  width="300px"
    > height="250px">
    >     <param name="movie"
    > value="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&MarketPlace=US...">
    >     <param name="quality" value="high">
    >     <param name="bgcolor" value="#FFFFFF">
    >     <param name="allowscriptaccess" value="always">
    >     <embed
    > src="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&MarketPlace=US..."
    > id="Player_31808dd6-254b-4a01-a484-3d300cef27c5" quality="high"
    > bgcolor="#ffffff" name="Player_31808dd6-254b-4a01-a484-3d300cef27c5"
    > allowscriptaccess="always"  type="application/x-shockwave-flash"
    > align="middle" height="250px" width="300px"></embed>
    >   </object>
    >   <noscript><a
    > href="http://ws.amazon.com/widgets/q?ServiceVersion=20070822&MarketPlace=US...">Amazon.com
    > Widgets</a></noscript>
    > </div>
    >
    > any suggesions?


    The problem here is that adding Flash requires special code that
    cannot be validated. For instance, <embed> is not a part of any
    standardized version of HTML. Read more on http://www.alistapart.com/articles/flashsatay
     
    Alexey Smirnov, Jan 26, 2010
    #2
    1. Advertising

  3. Jeff wrote:
    > A lot of the rest of the errors are because of using & in the
    > affiliate link. But I don't understand why that's wrong to use &. The
    > validator suggests using &amp; instead. Not sure what's best here...


    "Special" characters in URLs should be URL-encoded, e.g. if you want a link
    to

    http://www.example.com/x.aspx?a=1&b=2
    you enter it as
    <a href="http://www.example.com/x.aspx?a=1&amp;b=2">

    Andrew
     
    Andrew Morton, Jan 26, 2010
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. HDL Book Seller
    Replies:
    0
    Views:
    450
    HDL Book Seller
    Aug 6, 2004
  2. nospam
    Replies:
    13
    Views:
    623
    Guinness Mann
    Oct 7, 2003
  3. Xavier Osa
    Replies:
    0
    Views:
    653
    Xavier Osa
    Jan 9, 2004
  4. Titus A Ducksass - AKA broken-record
    Replies:
    6
    Views:
    670
    Titus A Ducksass - AKA broken-record
    Nov 15, 2004
  5. Replies:
    7
    Views:
    1,052
Loading...

Share This Page