W3C home > Mailing lists > Public > www-svg@w3.org > July 2000

Re: Dynamic linking of SVG's

From: Chris Lilley <chris@w3.org>
Date: Mon, 24 Jul 2000 17:51:16 +0200
Message-ID: <397C65F4.789B5FFD@w3.org>
To: andre <andre.simmons@exponent.co.uk>
CC: www-svg@w3.org


> andre wrote:
> 
> I am trying to find a way of dowloading bits of an SVG at a time, in
> seperate SVG files but still look like one SVG picture.

The symbol and use elements are your freind here.

> Say i have an SVG that i would like to download, its an SVG map with 3
> features, then on a user selection i need to add another two features.
> I know i can add all these in one file at the beginning and use
> JavaScript to turn layers on and off 

yes, though that involves donloading information the user might never view,
so as you say:

> but what i have is 3 features in a database
> to start with and then later 2 are added once the client has already
> downloaded the SVG 

You can do this by altering the xlink:href attribute on the use element to
point to a more detailed symbol. This change can either be made
declaratively, using the animation features, or can be done usingJavaScript
if the choice of symbol to use depends in a complex way on user
interaction.

--
Chris
Received on Monday, 24 July 2000 11:52:04 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 5 November 2012 23:52:47 GMT