473,807 Members | 2,766 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Blank xml tags; whats the deal?

Okay here is my question. I have an XSD and two pieces of
xml that look like this:
snippet1:
<myTag myattr="someVal "></myTag>
snippet2:
<myTag myattr="someVal "/>

Technically speaking both mean the same thing. I validated
both XML's using XMLSPY and they pass through. But one of
our clent uses the old style, that is snippet1. When he
get's snippet2, he encounters an error.

Does any one know about this kind of issues? As in what
part of the xml spec speaks about this? and what is this
called in terms of parser terminology?

Thanks in advance.
Nov 12 '05 #1
1 1449
Snippet 1 and 2 are identical. There is not an "old" version and a "new"
version. XML 1.0 simply states that all tags must be closed. Using a
self-terminating tag is just a shortcut to adhering to the rule.

The error may be caused by specifically attempting to work with the closing
tag. You need to give us some code to look at to give you further details.
"Rakesh" <aa***@myrealbo x.com> wrote in message
news:1c******** *************** *****@phx.gbl.. .
Okay here is my question. I have an XSD and two pieces of
xml that look like this:
snippet1:
<myTag myattr="someVal "></myTag>
snippet2:
<myTag myattr="someVal "/>

Technically speaking both mean the same thing. I validated
both XML's using XMLSPY and they pass through. But one of
our clent uses the old style, that is snippet1. When he
get's snippet2, he encounters an error.

Does any one know about this kind of issues? As in what
part of the xml spec speaks about this? and what is this
called in terms of parser terminology?

Thanks in advance.

Nov 12 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
3292
by: dan glenn | last post by:
Hi. I'm finding that if I have text entered into a <textarea ...> </textarea> in a form, and that text has leading blank lines (with no spaces or anything else), that when I retrieve the entered text, I lose the leading blank line. Each time it goes through a post any top-leading blank line is lost. Only one- if I have several blank lines in a row at the top, only the first is lost. (If the top blank line has a single space, it's handled...
9
7170
by: developer | last post by:
Does anyone know what is the way IE treats span tags(<span>) and table tags(<tr>, <td>)? Should the <span> tag be encolsed in tds and trs if it placed with other elements that are in a table? Can the span tag itself contain table tags within it? I have some scripting code and when I wrap the span in table elements it does not find the html within the span. Here is an example.... <tr><td colspan="4" align="left"><span...
2
1142
by: danmc91 | last post by:
I have a set of xml files and a .xsl file which I use to produce html output. However, I want 2 versions of each html file. In one version, I want the whole thing. In the second version I only want whats inclosed by the <body> tag. So, I tried defining a parameter which I can override on the command line and doing something like: <xsl:if test="$header = 'yes'"> <html>
5
2328
by: Tappy Tibbons | last post by:
I have a class I am serializing, and need the resultant XML to skip/omit classes that are not initialized, or their member variables have not been set. Is this possible? Say for the following code, sometimes the Person may not have given us one, both, or either of their addresses. The serialize function will still put in a "<BillingAddress />" tag indicating no data. I want it to completely omit the tag if the class is empty, similar...
1
1130
by: s.subbarayan | last post by:
Dear all, With respect to structures whats actually "tags" in C?Is is that tags are mainly used for self referential structures and what else are the purpose of using tags in C?How does a tag differ from typedef with respect to structures in C? Expecting all your replys and advanced thanks for the same, Regards, s.subbarayan
0
8375
by: Robert Seidl | last post by:
I saw that VB .Net 2003 has some tools for easily reading metadata information present in some TIFF and JPG files, eg. ---------------------------------------------------------------- .... Dim b As New Bitmap(OpenFileDialog1.FileName) For Each p As System.Drawing.Imaging.PropertyItem In b.PropertyItems ' do something with ' p.Id ' p.Len ' p.Type
3
3787
by: Baquanb | last post by:
I need to get some text between font tags but I only need the text in the last table. The code i'm using below will get text between all font tags anyone know how I can just get whats in TABLE3 font tags. $url = "http://www.mysite.com"; $data = implode("", file($url)); preg_match_all ("/<td>(*?)<\/td>/", $data, $matches); foreach ($matches as $match) {
7
50114
by: 一首诗 | last post by:
Is there any simple way to solve this problem?
6
1544
by: damod.php | last post by:
<?php ...<? both are the php tags whats the diff b/w name of the tag??? then i write the code using <? this tag full coding , but the server can not accept my (<?)tag,, its only used <? php tag only what can i do for ...
0
9599
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,...
0
10371
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10374
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10111
tracyyun
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...
0
5546
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...
0
5684
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4330
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3853
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3010
bsmnconsultancy
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...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.