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 8424553
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T04:01:32+00:00 2026-06-10T04:01:32+00:00

I wanted to ask if I could use the jQuery.parseXML(data) to validate XML string?

  • 0

I wanted to ask if I could use the jQuery.parseXML(data) to validate XML string?

I mean I know it’s used for parsing XML, and if the XML is not valid I will get an error message, but will the function fail every time that there will be even a minor error in the XML?

I’ve tried googling about it, but all I found is regarding parsing, and not about validation.

Thanks!

  • 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-06-10T04:01:33+00:00Added an answer on June 10, 2026 at 4:01 am

    No, not via jQuery (at least not in Mozilla and most likely the other non-IE browsers).

    In the case of IE, it is stated at http://msdn.microsoft.com/en-us/library/windows/desktop/ms754585%28v=vs.85%29.aspx , with loadXML, “You cannot use it to validate the XML document against a schema.”, so apparently the code used in jQuery at http://code.jquery.com/jquery-latest.js will not validate either.

    However, some code at http://www.stylusstudio.com/xsllist/200301/post50460.html seems to suggest it is possible in IE (only) with the right IE–at least with the 4.0 version of Msxml2.DOMDocument — since according to http://msdn.microsoft.com/en-us/library/aa468547.aspx#beginner_failure , “the MSXML parser will validate your document against a DTD or schema if either has been specified in the document” (unless validateOnParse property is set to false).

    However, with Mozilla and the other browsers, these do not perform validation (I thought they had loaded external DTDs in the case of DOMParser() of Ajax, but this does not seem to work for me now, and in any case, even entities are not loaded in regular websites).

    I don’t recall whether http://code.google.com/p/jssaxparser/ or http://debeissat.nicolas.free.fr/relaxng.php will support external validation, but I think you’d need to go in this kind of direction.

    Do you need to use XML? Perhaps JSONSchema could meet your needs? http://json-schema.org/implementations.html .

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

Sidebar

Related Questions

Just wanted to ask you about the drawbacks (I mean memory or reponse time)
I wanted to ask what is the idea behind the fact that System.String doesn't
I am a newbie in this and I wanted to ask if you could
I know this is somewhat of a server question, but I wanted to ask
I wanted to ask whether you know about some free C# libraries (dlls) that
I wanted to ask for a clarification about the use of RowFilter and its
just wanted to ask where I define initial class properties? From other languages I
I wanted to ask if there is any way i can get path of
I wanted to ask, how to implement an AdListner for Admob. I want the
I wanted to ask whether the following statement where printf() has been provided with

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.