Hi,
Is it legal or formal to nest tag names? My code is in the following.
The <name> is nested. I used java to read the xml file but it seems to
not know the nested structure. I need to write the nest structure as
it is a multi-level catalog description. That means a catalog is a
sub-catalog of the another. If it is illegal or not formal, how to
solve this?
Thanks!
<?xml version='1.0' encoding='utf-8'?>
<root>
<name>
All
</name>
<name>
<name>
Connector
</name>
<name>
Inline
</name>
<name>
PCB
</name>
</name>
<name>
Crystal_and_Res onator
</name>
:
: 3 1640
On 24 Nov 2004 21:38:57 -0800, le*******@yahoo .com (terry) wrote: Hi,
Is it legal or formal to nest tag names? My code is in the following. The <name> is nested. I used java to read the xml file but it seems to not know the nested structure.
.... <name> <name> Connector </name> <name> Inline </name> <name> PCB </name> </name>
Yes, this is legal, easily expressed in a DTD. An XML application that
comes immediately to mind is XBEL,
<http://pyxml.sourcefor ge.net/topics/xbel/>, the bookmark exchange
language, in which folders can contain other folders. If your java is
not seeing the structure, it's probably a bug in the parser you're
using, or more likely a bug in your own code.
--
Morris M. Keesan -- ke****@alum.bu. edu
Morris M. Keesan <ke****@alum.bu .edu> wrote in message news:<nd******* *************** **********@4ax. com>... On 24 Nov 2004 21:38:57 -0800, le*******@yahoo .com (terry) wrote:Hi,
Is it legal or formal to nest tag names? My code is in the following. The <name> is nested. I used java to read the xml file but it seems to not know the nested structure. ... <name> <name> Connector </name> <name> Inline </name> <name> PCB </name> </name>
Yes, this is legal, easily expressed in a DTD. An XML application that comes immediately to mind is XBEL, <http://pyxml.sourcefor ge.net/topics/xbel/>, the bookmark exchange language, in which folders can contain other folders. If your java is not seeing the structure, it's probably a bug in the parser you're using, or more likely a bug in your own code.
Could u explain how to use DTD to do this?
"terry" <le*******@yaho o.com> wrote in message
news:99******** *************** **@posting.goog le.com... Morris M. Keesan <ke****@alum.bu .edu> wrote in message
news:<nd******* *************** **********@4ax. com>... On 24 Nov 2004 21:38:57 -0800, le*******@yahoo .com (terry) wrote:Hi,
Is it legal or formal to nest tag names? My code is in the following. The <name> is nested. I used java to read the xml file but it seems to not know the nested structure. ... <name> <name> Connector </name> <name> Inline </name> <name> PCB </name> </name>
Yes, this is legal, easily expressed in a DTD. An XML application that comes immediately to mind is XBEL, <http://pyxml.sourcefor ge.net/topics/xbel/>, the bookmark exchange language, in which folders can contain other folders. If your java is not seeing the structure, it's probably a bug in the parser you're using, or more likely a bug in your own code.
Could u explain how to use DTD to do this?
You could write a DTD to inform XML processors to enforce structure rules,
such as "a 'name' element may contain zero or more 'name' elements".
This probably won't help with your current problem.
But what is your current problem, exactly? It is not at all clear what you
mean by "[my program does] not know the nested structure". If you need
further help, you should provide details about your program and the problem
you are seeing.
/kmc This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Martin |
last post by:
Hallo,
can you help me writing a generic xslt transformation (useable with
xsql from oracle)? The problem is how to get the escaping characters
....
=== INPUT-File in.xml
<?xml version = '1.0'?>
<person><who>scott</who></person>
|
by: darrel |
last post by:
I know you CAN'T nest templates, so what would be the logic to use
otherwise?
Here's what I am doing:
I have a template set to match a specific node based on one of it's
elements.
If it finds it, it renders it. I then want to see if that node has any
children. If it does have children, render that. Since I can used a nested
|
by: Chad |
last post by:
I want to nest a grid within a MS Treeview ASP Web Control.
It seems that I cannot add controls to a nodes Controls collection, however,
I can put HTMLText in the Node.Text property of a Node object.
The problem is, how can I get the Html text associated with any normal Web
Control? I see it has a Render method, but it seems that that will only
render the object without ever exposing the underlying HTml text to you, but
I need to place...
|
by: edu |
last post by:
there some way to nest transactions with bd destination sql server?
thank you
|
by: Dave |
last post by:
If so, what is wrong with this code in APS 3.0?
I open a recordset with order info. Each record contains the order header
info plus a line item from the order detail. So the recordset looks
something like this:
Orderid PartID
1 12
1 87
2 99
| |
by: Tim Streater |
last post by:
Not sure is this is quite the right NG, but anyway:
I have rows in a table which I want to have represent nested data, which
I want to show and hide. I can hide a row easily enough by doing:
object.style.display = 'none'; and
object.style.display = '';
but for nested data it gets a lot more complex (imagine how with
Explorer you click on the little plus and minus to expose or hide nested
|
by: Steven Nagy |
last post by:
Hi all,
ASP.NET : Framework 2.0 - C#
A recent addition to my code generater will create GridView's and
ObjectDataSource's in a control (ASCX).
So the code gen creates an ascx, ascx.cs, ascx.designer.cs and a
stylesheet.
The 3 control files are placed together.
|
by: Al |
last post by:
Hi all,
(Apologies if this is in a FAQ somewhere, I couldn't find anything).
Almost every time I do any significant amount of coding in C or C++, I
end up wishing C-style comments would nest. It would make rapid
debugging much more convenient (vs. #if 0/#endif or editor macros).
Anyway, was this an explicit design decision, or some sort of historical
artifact? (e.g. too expensive to parse at the time). What other sorts of
|
by: kmartinenko |
last post by:
Hi,
I am very new to Python and I would like to know if it is possible to nest 'for' statements?
The question precipitates from a certain problem I am having with running a simple calculation on a column in a .csv file. I want to read columns from an existing .csv file and write out selected columns from the .csv file along with the new column containing the results from the calculation to a new .csv file.
I am thinking the way to do...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |