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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T14:53:46+00:00 2026-05-30T14:53:46+00:00

I have document <?xml version=1.0 encoding=utf-8 ?> <!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.1//EN http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd>

  • 0

I have document

<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<body>
</body>
</html>

When I use this code in IDispatchMessageFormatter with code to generate html page:

XmlReaderSettings settingsReader=new XmlReaderSettings();
settingsReader.ProhibitDtd=false;
                        settingsReader.DtdProcessing=DtdProcessing.Parse;
settingsReader.ValidationEventHandler+=new System.Xml.Schema.ValidationEventHandler(settingsReader_ValidationEventHandler);
XhtmlUrlResolver resolver=new XhtmlUrlResolver();
                        Uri baseUri=new Uri("http://localhost/App_Data/dtd");

                        Uri fulluri=resolver.ResolveUri(baseUri,"xhtml11.dtd");

                        // Get a stream object containing the XSL file
                        Stream s=(Stream)resolver.GetEntity(fulluri,null,typeof(Stream));

                        //Read the stream object displaying the contents of the XSL file
                        settingsReader.XmlResolver=resolver;

                        MemoryStream ms=new MemoryStream(Encoding.UTF8.GetBytes((MessageBody)));
                        ms.Position=0;

                        XmlReader reader=XmlReader.Create(ms,settingsReader);
                        MessageResponse=Message.CreateMessage(messageVersion,string.Format("ServiceModel/IService/{0}",Operation),reader);

Html page doctype is generate as

<html version="-//W3C//DTD XHTML 1.1//EN" xmlns="http://www.w3.org/1999/xhtml">

I can not find a way to page contain doctype in good way :

  • 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-30T14:53:48+00:00Added an answer on May 30, 2026 at 2:53 pm

    Only solution is send message as binary. I wrote it on blog http://netmajor.wordpress.com/2012/01/27/jak-przeslac-xhtml-wraz-z-doctype-w-obiekcie-message-za-pomoca-wcf/

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

Sidebar

Related Questions

<?xml version=1.0 encoding=UTF-8 standalone=no?> <!DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.1//EN http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd> <html xmlns=http://www.w3.org/1999/xhtml> <head>
I have the following JSF table: <?xml version=1.0 encoding=UTF-8?> <!DOCTYPE html PUBLIC -//W3C//DTD XHTML
I have the following code. <?xml version=1.0 encoding=UTF-8 standalone=no?> <!DOCTYPE html PUBLIC -//W3C//DTD XHTML
I have this piece of html: <?xml version=1.0 encoding=UTF-8?> <!DOCTYPE html PUBLIC -//W3C//DTD XHTML
I have a document like this: <?xml-stylesheet type=text/css href=http://ltw1001.web.cs.unibo.it/svg.css encoding=UTF-8?> <!DOCTYPE html PUBLIC -//W3C//DTD
Here's an example of an XML file created in InfoPath: <?xml version=1.0 encoding=UTF-8?> <?mso-infoPathSolution
Consider the following XML: <?xml version=1.0 encoding=UTF-8?> <OS> <data> <OSes> <centos> <v_5> <i386> <id>centos5-32</id>
Something's screwy here. I'm trying to parse this XSL file: <?xml version=1.0 encoding=utf-8?> <xsl:stylesheet
Below is the XML schema I am trying to conform to: <?xml version=1.0 encoding=UTF-8?>
I have an XML document, and I want to print the tag names and

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.