Click here to Skip to main content
15,908,834 members
Home / Discussions / XML / XSL
   

XML / XSL

 
GeneralRe: reading attributes Pin
Stephane Rodriguez.15-Jan-03 6:41
Stephane Rodriguez.15-Jan-03 6:41 
Generalattribute vs. node Pin
Marc Clifton14-Jan-03 1:19
mvaMarc Clifton14-Jan-03 1:19 
GeneralRe: attribute vs. node Pin
Michael A. Barnhart14-Jan-03 1:36
Michael A. Barnhart14-Jan-03 1:36 
GeneralRe: attribute vs. node Pin
Michael A. Barnhart14-Jan-03 1:38
Michael A. Barnhart14-Jan-03 1:38 
GeneralRe: attribute vs. node Pin
Marc Clifton14-Jan-03 1:45
mvaMarc Clifton14-Jan-03 1:45 
GeneralRe: attribute vs. node Pin
Stephane Rodriguez.14-Jan-03 1:54
Stephane Rodriguez.14-Jan-03 1:54 
GeneralRe: attribute vs. node Pin
Michael A. Barnhart14-Jan-03 1:59
Michael A. Barnhart14-Jan-03 1:59 
GeneralRe: attribute vs. node Pin
Michael Dunn15-Jan-03 18:08
sitebuilderMichael Dunn15-Jan-03 18:08 
The way I do it is, if something is a container, then it has subnodes. For example, if you're describing a menu in XML:

<menu>
<menuitem type='command' text="Run MS Word' program='winword.exe' />
<menuitem type='separator' />
<menuitem type='command' text="Run MS Excel' program='excel.exe' />
</menu>

A <menu> is a container for other things (items). A <menuitem> itself is just a thing, but it has various properties (type, text for the menu, and what app to run). Since those properties are simple values, they go as attributes.

In your sample, there is no reason to have title and price as nodes IMHO.

GeneralRe: attribute vs. node Pin
Michael A. Barnhart15-Jan-03 23:26
Michael A. Barnhart15-Jan-03 23:26 
GeneralRe: attribute vs. node Pin
Michael Dunn16-Jan-03 9:48
sitebuilderMichael Dunn16-Jan-03 9:48 
GeneralRe: attribute vs. node Pin
Christian Graus15-Jan-03 18:22
protectorChristian Graus15-Jan-03 18:22 
GeneralRe: attribute vs. node Pin
Stephane Rodriguez.16-Jan-03 2:07
Stephane Rodriguez.16-Jan-03 2:07 
GeneralRe: attribute vs. node Pin
Christian Graus16-Jan-03 10:17
protectorChristian Graus16-Jan-03 10:17 
GeneralSome questions about XML Pin
Marc Clifton12-Jan-03 10:52
mvaMarc Clifton12-Jan-03 10:52 
GeneralRe: Some questions about XML Pin
Christian Graus12-Jan-03 11:06
protectorChristian Graus12-Jan-03 11:06 
GeneralRe: Some questions about XML Pin
Marc Clifton12-Jan-03 14:29
mvaMarc Clifton12-Jan-03 14:29 
GeneralRe: Some questions about XML Pin
Michael A. Barnhart12-Jan-03 14:43
Michael A. Barnhart12-Jan-03 14:43 
GeneralRe: Some questions about XML Pin
Stephane Rodriguez.14-Jan-03 4:08
Stephane Rodriguez.14-Jan-03 4:08 
GeneralRe: Some questions about XML Pin
Taka Muraoka12-Jan-03 11:58
Taka Muraoka12-Jan-03 11:58 
GeneralRe: Some questions about XML Pin
Marc Clifton12-Jan-03 14:34
mvaMarc Clifton12-Jan-03 14:34 
GeneralRe: Some questions about XML Pin
me12-Jan-03 13:14
me12-Jan-03 13:14 
GeneralRe: Some questions about XML Pin
Marc Clifton12-Jan-03 14:35
mvaMarc Clifton12-Jan-03 14:35 
GeneralRe: Some questions about XML Pin
me12-Jan-03 16:03
me12-Jan-03 16:03 
GeneralRe: Some questions about XML Pin
Michael A. Barnhart12-Jan-03 14:19
Michael A. Barnhart12-Jan-03 14:19 
GeneralRe: Some questions about XML Pin
Marc Clifton12-Jan-03 14:42
mvaMarc Clifton12-Jan-03 14:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.