<object> tag with pdf doesn't work in firefox and is messed up in IE

后端 未结 6 537
别那么骄傲
别那么骄傲 2021-01-04 09:26

I have object tag that look like this :

\" id=\"embedde
6条回答
  •  离开以前
    2021-01-04 09:38

    When you deliver dubious HTML:

    " id="embeddedPdf" width="820" height="1135" type="application/pdf">
    ^ ^ | | Start End?

    ... browsers try to figure out what you had in mind, with a varying degree of success that depends on the algorithms they implement and how imaginative the webmaster is. Different browsers can't always agree on how to handle valid code (where there're clear rules and specs) so it's to expect that the level of disagreement increases with invalid code.

    IMHO, the simplest path to obtain cross-browser compatibility is to generate valid code. As help, you can use the on-line W3C HTML validator or whatever equivalent tool your IDE provides.

提交回复
热议问题