<community>of XML and SVG Developers</community>
This is a discussion on xml handling within the SVG Questions forums, part of the SVG Forums category; hi, in my map i have several objects.each object has a id. then i hava separate xml file containg data ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| in my map i have several objects.each object has a id. then i hava separate xml file containg data about each and every object.one tag contains the id field to identify the object. when i click on the particular object i want to display those data. is there any way to do this with svg. have we use to any client side or server side scripting? pls send your suggestions regards, kelum. |
| |||
|
You can with getURL and parseXML get your xml nodes. You can append this nodes to your svg. On click, you can client side find data and display them. You can also add your data as parameter of your choice to your svg tag and display them. Michel |
| |||
|
as you mentioned above i add the xml to existing node like below. this xml contains <objectInfo id='objectData'> <object id='aaa'> <name>Empire Burlesque</name> <address>Bob Dylan</address> </object> </objectInfo> function getObjects() { svgdoc4 = evt.target.ownerDocument getURL("objectInfo.xml",callback1) } function callback1(data) { if (data.success) { object_node= parseXML(data.content,svgdoc4) svgdoc4.getElementById("base").appendChild(object_ node) } } then i try to retrive this.it will give errors. function getObjectInfo(evt){ getObjects() svgdoc3 =evt.target.ownerDocument //retreive data from added xml cnodes=svgdoc3.getElementById("objectData").childN odes nodeVal=cnodes.item[0].getAttributeNS(null,"id") //display idVal = svgdoc3.getElementById("idVal"); idVal =idVal.getFirstChild(); idVal.setData(nodeVal) } |
| |||
|
I am having the same problem have reched anything yet.... please if yea,,,,mail me shourbagui@gmail.com or amshourbagui@yahoo.com with the svg developers group |
Printer Inks...
Order all printer inks and digital requirements from this company.
Hard Disk Drive Data Recovery Cheshire...
Recover data from servers, desktops/laptops, DVDs and CDs! Visit this site.