You need to be logged in to post in the forums. If you do not have an account, please sign up first.
Opera and inline SVG
I'm using inline SVG.It works in FireFox, Chrome, and the various Gtk Webkit browsers but does not seem to work in Opera.
Example:
http://www.shastaherps.org/herps/OregonEnsatina_intergrade_
There should be an SVG range map below the "Distribution Range" heading, as a child of an anchor node pointing to a standalone version.
Instead, Opera only shows the text portion of the SVG.
I test for SVG support in the browser by seeing if the browser supports canvas, and Opera seems to pass that test, but it does not render the SVG.
The page validates using 2 different HTML 5 validators, and Opera clearly supports SVG. Any clue why it isn't working here?
x86_64, 2.6.31-20-generic
Opera 10.10 build 4742
Opera/9.80 (X11; Linux x86_64; U; en) Presto/2.2.15 Version/10.10
The page doesn't validate on the W3C validator (which I would recommend as the place to start): http://validator.w3.org/
It only reports one error:
It only reports one error:
Element svg not allowed as child of element a in this context
It was a bright, cold day in April...
Geez - the problem (with validator anyway) is that Opera is getting HTML version instead of XHTML version, which validates.
I thought I fixed that - opera reported its xhtml ability differently than other browsers (requiring a preg on accept string to get rid of space)
I'll have to check what went wrong in my scripts to break the server detecting Opera's xhtml capability in the accept header again.
I believe svg can be a child of the anchor element in html 5 (earlier html svg isn't a valid tag), but I don't believe xmlns is a valid attribute unless the document is sent as xml, that may be the actual problem.
The link validates with the FireFox accept string (open page in FireFox and click on valid markup button) as it then is sent as xhtml.
I thought I fixed that - opera reported its xhtml ability differently than other browsers (requiring a preg on accept string to get rid of space)
I'll have to check what went wrong in my scripts to break the server detecting Opera's xhtml capability in the accept header again.
I believe svg can be a child of the anchor element in html 5 (earlier html svg isn't a valid tag), but I don't believe xmlns is a valid attribute unless the document is sent as xml, that may be the actual problem.
The link validates with the FireFox accept string (open page in FireFox and click on valid markup button) as it then is sent as xhtml.
Originally posted by funkyres:
I believe svg can be a child of the anchor element in html 5
I don't think this is true. The HTML5 spec (at present) doesn't allow interactive content within an anchor. Since SVG can have anchors within it it comes under the interactive heading.
After all, what should the browser do if you click on an anchor in an svg image, when the image itself is within an anchor? Which link do you follow?
Also, validation should be browser independent. If you're using the validate buttons available within a browser, then it might be sending the source it has received to the validator instead of pointing the validator to the url, which could explain the difference in behaviour. I prefer to enter the url directly in to the validator so it gets the raw source I've provided.
It was a bright, cold day in April...
Forums » General Opera topics » Opera and cross-browser Web design