473,797 Members | 3,096 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

What am I doing wrong? ("Debug" XML code help please.)

Hi,

xmllint --valid gives error output on some code (included below:)

file "Shotgun_Robot. dtd" (don't ask)

<!ELEMENT Image (#PCDATA) > <!-- #PCDATA == image path -->

<!-- x/y values default to 0, w/h values default to image w/h-->
<!ATTLIST Image
srcrect_x CDATA #IMPLIED
srcrect_y CDATA #IMPLIED
srcrect_w CDATA #IMPLIED
srcrect_h CDATA #IMPLIED

<!-- If element content is empty, the Drawable name points to an
already created Drawable. If it is not empty, it defines a
Drawable of the name and type given. -->
<!ELEMENT Drawable (EMPTY|Image|Mu p)
<!ATTLIST Drawable
name CDATA #REQUIRED


<!ELEMENT Mup (Drawable)* >
file "image_test.xml "

<?xml version="1.0"?>

<!DOCTYPE root SYSTEM "Shotgun_Robot. dtd" [
<!ELEMENT root ANY>
]>

<root>

<Drawable name="mup1">
<Mup>
<Drawable name="t43a">
<Image>images/sprites/tank_ClassicTra ckT43A.png</Image>
</Drawable>
<Drawable name="t43a" />
<Drawable name="mup1" />
</Mup>
</Drawable>

</root>
error output:

image_test.xml: 14: validity error: Element Drawable content does not
follow the DTD
Expecting (EMPTY | Image | Mup), got
<Drawable name="t43a" />
^
image_test.xml: 15: validity error: Element Drawable content does not
follow the DTD
Expecting (EMPTY | Image | Mup), got
<Drawable name="mup1" />
^
<?xml version="1.0"?>
<!DOCTYPE root SYSTEM "Shotgun_Robot. dtd" [
<!ELEMENT root ANY>
]>
<root>

<Drawable name="mup1">
<Mup>
<Drawable name="t43a">
<Image>images/sprites/tank_ClassicTra ckT43A.png</Image>
</Drawable>
<Drawable name="t43a"/>
<Drawable name="mup1"/>
</Mup>
</Drawable>

</root>
Wha??

Thanks,
Asfand Yar

--
http://www.it-is-truth.org/

Jul 20 '05 #1
2 2380
In article <bk**********@n ewsg4.svr.pol.c o.uk>,
Asfand Yar Qazi <im_not_giving_ it_here@i_hate_ spam.com> wrote:

% <!-- If element content is empty, the Drawable name points to an
% already created Drawable. If it is not empty, it defines a
% Drawable of the name and type given. -->
% <!ELEMENT Drawable (EMPTY|Image|Mu p)
% >
This says that Drawable takes one of three elements as content:
EMPTY, Image, or Mup. What you want is

<!ELEMENT Drawable (Image|Mup)?


This says that the content is zero or one of either Image or Mup.
--

Patrick TJ McPhee
East York Canada
pt**@interlog.c om
Jul 20 '05 #2
Patrick TJ McPhee wrote:
In article <bk**********@n ewsg4.svr.pol.c o.uk>,
Asfand Yar Qazi <im_not_giving_ it_here@i_hate_ spam.com> wrote:

% <!-- If element content is empty, the Drawable name points to an
% already created Drawable. If it is not empty, it defines a
% Drawable of the name and type given. -->
% <!ELEMENT Drawable (EMPTY|Image|Mu p)
% >
This says that Drawable takes one of three elements as content:
EMPTY, Image, or Mup. What you want is

<!ELEMENT Drawable (Image|Mup)?
>


This says that the content is zero or one of either Image or Mup.


(Sorry for the late reply...)

Ohh... now I see...

Thanks.

--
http://www.it-is-truth.org/

Jul 20 '05 #3

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

Similar topics

1
4443
by: asdf | last post by:
Hello, I was enjoying working in VS for half a year without any problems and now I cannot debug anymore. Without any really reason my Studio tells me that the page that I want to debug has - No symbols loaded. I use VS v1.7.3088 and .NET framework v1.1.4322 SP1. I work with ASP.NET using VB and I'm trying to set a breakpoint on the ascx.vb file.
4
4303
by: A_StClaire_ | last post by:
I read a section of my text on smart "counting" pointers and found it confusing so I decided to get hands-on. however I'm getting "Debug Assertion Failed... Expression: _BLOCK_TYPE_IS_VALID(pHead->nBlockUse)" whenever I run my code below. program works fine after I bypass the msg. any ideas? thx a lot.
10
28667
by: John Smith | last post by:
After reading C# documentation the Conditional attribute seemed the way to go, but after inspecting the IL it seems those methods are still there and I imagine the CLR removes them. Using #if DEBUG means the code does not even reach the IL when compiling in release mode. Is there any benefit to using the Conditional Attribute? Am I right in thinking there will small performance overhead using over #if DEBUG.
2
1690
by: Axel Dahmen | last post by:
Hi, when applying changes to the code and hitting to debug, a MessageBox pops up asking me if I want to build before debugging. Of course I want, that's why I've changed the code... Is there a simple way to suppress this MessageBox in Studio 7 and to start a Build-Debug sequence immediately? TIA, Axel Dahmen
1
5882
by: Alexander Walker | last post by:
Hello I have recently published a web application using the "Publish Web Site" option of the solution explorer from Visual Studio 2005, I have published the website so that the pages could not be updated, do I need to set the web.config so that it contains <compilation defaultLanguage="c#" debug="false"> before I publish the web site or can I make this configuration change on the deployment machine after the site has been deployed? ...
3
3111
by: André | last post by:
Hi, I put that question already, but it's still not very clear to me, so ... Assume following option in web.config= debug="false" but in one aspx page (test.aspx) <%@ debug="true" ..%>
2
2343
by: bbasberg | last post by:
Hello, I am a neophyte with Visual Basic but have been trying to hurry and get up to speed. I used to be able to "step into" code using Debug..step into but for the last couple of days I am unable to. Regardless of where in the code I place my cursor, I hear a microsoft error "thunk" and step into doesn't work. I am using VBA in Access if that matters. here's one possible clue but it may just be a coincidence: I tried some example...
2
1852
by: Joe Stateson | last post by:
I added ajax to an existing web project. It runs fine but hitting F5 (debug) in Visual Studio 2005 slowly consumes resources: Kernel Memory and System Cache grow and I start seeing "Loading symbols for C:\WINDOWS\assembly\GAC_MSIL\System.Web.Extensions\1.0.61025.0___\System.Web.Extensions.dll" in the VS2005 footer. After several hours of coding and debugging it can take 2 minutes before that "loading symbols" finally finishes. ...
1
3877
by: =?Utf-8?B?RWluYXY=?= | last post by:
hi, im developing a dll app under vs2005 (sp1). when trying to load my exe app (which uses the dll) im getting the following err message: "the application failed to initialize properly (0xc0000005)" im using a third party lib (qt 3.3.8) to create the gui. although eliminating it did solve to problem. im running in debug mode. i've used depends.exe and made sure all the dlls depend on the debug runtime dlls all depend on MSVCP80D.DLL and...
0
9538
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
10470
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10247
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
10214
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
5459
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
5583
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4135
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
3751
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2935
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.