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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T06:53:19+00:00 2026-06-06T06:53:19+00:00

I have an XML file that is well formed and valid (matched with an

  • 0

I have an XML file that is “well formed and valid” (matched with an XSD schema, tested at http://xsdvalidation.utilities-online.info/).

I am using these lines of code in the XSD to restrict the XML input of a <firstname>:

<xsd:pattern value = "[A-Z][a-z]+" />
<xsd:minLength value = "2" />
<xsd:maxLength value = "25" />

So, the website mentioned above will throw an error and not validate when the <firstname> does not match this regex and length restrictions (say, if I enter “5” as the first name in the XML file).

But, when I open the XML file into Firefox (parsed into HTML with an XSL file), it does not throw an error and will display whatever is entered into the XML file regardless of the regular expression and length restrictions.

Are XSD schemas not meant to be used in this way, to error check in web browsers? Do I need to use the restrictions in the XSLT instead of the XSD?

  • 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-06T06:53:20+00:00Added an answer on June 6, 2026 at 6:53 am

    XPath 2.0 (and XSLT 2.0) is a strongly-typed language,where all built-in and user-defined schema types can be validated.

    One can use an XSLT 2.0 SA (Schema- oriented) processor to enforce schema type validation of:

    1. A source XML document.

    2. The value of any parameter passed to a template/(xsl:)function or (externally) to the stylesheet.

    3. The value of any xsl:variable.

    4. The result produced by any template or xsl:function

    Using these features properly makes unnecessary any post-transformation validation of the transformation result.

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

Sidebar

Related Questions

I have an XML file that I used to create an XSD File and
Well, i have this thing, i need to edit a XML file that is
well i have a xml file that i use to store location names with
I have an XML file that looks like <?xml version='1.0' encoding='UTF-8'?> <root> <node name=foo1
I have an XML file that has a number of nodes, each of which
I have an XML file that is very long, but here is a shot
I have an XML file that lists a series of items, and the items
I have an XML file that I'm trying to serialize into an object. Some
I have an xml file that I want to configure using a bash script.
I have an XML file that I would like to map some attributes of

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.