SVG Fragment Identifiers

An SVG feature appearing for the first time in Firefox 15 is support for SVG Fragment Identifier linking. This feature allows authors to display different parts of an SVG image by specifying a different fragment identifier on the end of the URL.

The Firefox 15 implementation also includes support for the view element which is basically a predefined fragment identifier. It does not however, support XPointer style fragment identifiers.

One use case for fragment identifers could be an SVG document with a set of sprites arranged in a grid. Fragment identifiers could then be used to display one or more of those images on another html or svg page.

Here’s an example that shows Fragment Identifier Linking in action

About these ads

One response to this post.

  1. [...] first read about SVG Fragment Identifiers on Robert Longsonā€™s blog. The SVG spec has further details (including extra parameters). If you [...]

Comments are closed.

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: