Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 592935
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T15:47:32+00:00 2026-05-13T15:47:32+00:00

I’ve got some XML files that recently changed so that some of the nodes

  • 0

I’ve got some XML files that recently changed so that some of the nodes now have the attribute xsi:nil=”true”. I’ve got an XSLT style sheet that renders the XML into HTML for some quick eyeballing of data. Currently to make things easier on myself I strip out the namespaces out of the XML before I apply the style sheet. That worked fine up till our last update. Now I’m getting an error because the XSL doesn’t know how to handle the xsl:nil=”true”.

I can easily update the code so I do a replace/remove on all the xsl:nil=”true” matches in the XML before I transform it, but I was wondering if it is possible to cludge the XSLT style sheet so that xsi:nil’s will be ignored/not cause transformation failures even if no namespaces are including in the XML. I would prefer to do things this way because I can make the change on the server now, where if I have to issue a new web build I have to jump through some internal hoops to get it deployed.

After I get things working (either through removing the xsl:nil’s before or during the transformation) I’ll circle back around and figure out why I removed the namespaces originally and fix that.

Thanks for any help you can give me.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T15:47:32+00:00Added an answer on May 13, 2026 at 3:47 pm

    Why did you remove the namespaces in the first place? The XSLT lets you control what prefixes shall not be put into the output, and you can skip those xsi:nil nicely in the stylesheet.

    If there is no namespace prefix declaration for the xsi prefix, the XML is not valid. So either you are dealing with invalid XML or you still have some XSI namespace declaration somewhere, and you could change the XSLT to skip those entries.

    If you do a find-replace on the XML source, really make sure to fix it later (soon!), because this kind of stuff is going to break your neck.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have just tried to save a simple *.rtf file with some websites and
I have a jquery bug and I've been looking for hours now, I can't
I've got a string that has curly quotes in it. I'd like to replace
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have thousands of HTML files to process using Groovy/Java and I need to
I have a bunch of posts stored in text files formatted in yaml/textile (from
I'm working with an upstream system that sometimes sends me text destined for HTML/XML

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.