Create !DOCTYPE... tag

Is any method in Java which can create the Doctype parameter in the XML document, that is to produce <!DOCTYPE Response SYSTEM "MyResponse.dtd">??
I use com.ibm.xml.parser and org.w3c.dom classes.
Thanks!!

You can create a new DocumentType using DOMImplementation.createDocumentType(), then append is as a child to your document node.
DOMImplementation domImpl = theDocument.getImplementation();
theDocument.appendChild(domImple.createDocumentType(qname,publicId,systemId));
Hope this helps,
Brian

Similar Messages

  • Is there a way to create editable tags in a dashboard section?

    Is there a way to create editable tags in a dashboard section?
    The requirement is - User should be able to enter comments in a edit box for a section in a dashboard and save it. For other users, this should show up as a non-editable comment while for the user it should be editable box.
    Example: In a report in a section on dashboard for Supplier Trends, a Purchase Manager should enter the commments -" This weeks trends show no issues. Next week watch out for supplier X". For everyone other than him, this should show up as comments.
    1. Is there a way to achieve this functionality?
    2. Can this be achived using write back option?
    3. Or will this require java scripting?
    Thanks

    Hi,
    If you want to have a better experience of your music files, how about just use WMP to enjoy all the songs, you can
    sort by Artists or Album or whatever you like. There, you can have a better and easier way to organize all your music
    files.
    For Windows Explorer, did you mean
    medium size icons in artist, while list icon in albums, you can just organize as you want like the following screenshot.
    If I'm missing something, please free contact me.
    Regards
    Yolanda
    TechNet Community Support

  • Can't create a Tag in a Yosemite

    Hi !
    After upgrading to Yosemite, I can't create a tag on my file or folder.
    I tried several methods(type in a tag name, click on an existing tag...), but it doesn't work.
    I'm using Macbook Air, Yosemite 10.10.1
    Please let me know what's the problem
    Thank you for your help

    Thank you for your help
    It worked, and after that, even without control key I could create a tag
    Thanks a lot ~~

  • Java mapping for Remove and Add of  DOCTYPE Tag

    HI All,
    i have one issue while the Java mapping for Remove and Add of  DOCTYPE Tag   in Operation Mapping .
    it says that , while am testing in Configuration Test "  Problem while determining receivers using interface mapping: Error while determining root tag of XML"
    Receiver Determination...
    error in SXMB MOni
    " SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="RCVR_DETERMINATION">CX_RD_PLSRV</SAP:Code>
      <SAP:P1>Problem while determining receivers using interface mapping: Error while determining root tag of XML: '<!--' or '<![CDATA[' expected</SAP:P1>
    plz provide solutions
    Thanks in advance.

    Hi Mahesh,
    I understand, you are using extended Receiver Determination using Operational Mapping (which has Java Mapping). And, there is an error message u201CError while determining root tag of XMLu201D, when you are doing configuration test.
    Can you please test, the Operational Mapping (which has Java Mapping) separately in ESR, with payload which is coming now. It should produce a XML something like this [Link1|http://help.sap.com/saphelp_nwpi711/helpdata/en/48/ce53aea0d7154ee10000000a421937/frameset.htm]
    <Receivers>
    <Receiver>
      <Party agency="016" scheme="DUNS">123456789</Party>
      <Service>MyService</Service>
    </Receiver>
    <Receiver>
      <Party agency="http://sap.com/xi/XI" scheme="XIParty"></Party>
      <Service>ABC_200</Service>
    </Receiver>
    </Receivers>
    If it is not (I Think it will not), then there is some problem in Java Mapping coding. Please correct it. Last option, if your Java code is small in length; you may paste it here, so that we can have a look at the cause of issue.
    Regards,
    Raghu_Vamsee

  • Is it possible to create a tagged pdf with apple pages?

    Not sure if possible and any tutorials would be appreciated.

    > Is it possible to create a tagged PDF with Apple Pages?
    Short answer: No, Apple chose at the introduction of Mac OS X to support only Adobe PDF 1.3 and those parts of Adobe PDF 1.4 that include device-independent transparency, but not those parts of Adobe PDF 1.4 that include Adobe XMP for XML markup of the page description program.
    Long answer: Adobe PostScript is a page description programming language, unlike Xerox Interpress which is a page and document description programming language. In other words, Adobe PostScript is a streaming or sequential rendering model that cannot simulate the behaviour of a bound book where the user can turn from any one page to any other page arbitrarily. Adobe introduced Acrobat Distiller in 1993 in order to convert Adobe PostScript page description programs into Adobe PDF page and document description programs that share the same fundamental functionality as Xerox Interpress.
    Conversion from Adobe PostScript to Adobe PDF buys one nothing but page-independent processing. Specifications published by Adobe in 1993 state how the SFNT Spline Font file format used by Apple and Microsoft for Unicode imaging has to be re-encoded into PostScript font program dictionary format (PostScript so-called simple fonts with less than 256 glyphs and PostScript so-called complex fonts (CID fonts) which are simple fonts tiled into a single superfont). All that is left is the glyph identifiers, and per Unicode Specification version 1.0 the glyph identifiers are private and font-dependent, so no character information can be inferred.
    ISO 19005:2005 PDF/A is a superset of ISO 15930:2002 PDF/X-3. The problem with ISO 15930:2002 PDF/X-3 is the same as above, that is, Adobe PostScript cannot encode the file format of the International Color Consortium, which has to be re-encoded to PostScript CSA Color Space Arrays and PostScript CRD Color Rendering Dictionaries. It is possible to encode the ICC file format directly in PDF 1.3 and higher, as specified in ISO 15930 and ISO 19005, but because PDF encodes only the glyph identifiers that are the output of the SFNT file format, and not the UCS Universal Character Set input and the settings for the feature selectors in the font file, ISO 19005:2005 has come under criticism for failing to support search in complex scripts.
    ISO 19005:2011 is supposed to address the shortcomings by saving the UCS input into the PDF itself, but in this case it is impossible to use Adobe PostScript and Adobe Acrobat Distiller as intermediates to Adobe PDF. So in order to drive ISO 19005:2011 Adobe would have to ditch Adobe Acrobat. I am not sure if there is software that implements ISO 19005:2011, but I noted that the Apple iBook Store does not accept PDF at all. Personally, I struggle to think of how to explain to endusers the overwhelming number of Adobe ISO PDF formats (there is PDF/E, PDF/UA and whatever else), and the overwhelming number of Adobe ISO PDF versions of these formats (there is ISO 19005:2005, ISO 19005:2011, ISO 15930 all the way back to 1999/2000 in God knows how many versions at this point).
    Best wishes,
    Henrik Holmegaard
    would-be technical writer

  • JAXP seems to be stripping off DOCTYPE tag

    When I parse a document, the DOCTYPE tag is getting stripped off.
    To parse, I read the document from file and it looks like :
    <?xml version="1.0" encoding="UTF-8" ?>
    <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
    <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j">
    After parsing, I dump it to the console and it looks like:
    <?xml version="1.0" encoding="UTF-8"?>
    <log4j:configuration debug="null" threshold="null" xmlns:log4j="http://jakarta.apache.org/log4j">
    The mystery the output has two attributes set to defaults, the only the parser knows this is by reading the dtd. But why does not include the DOCTYPE tag?
    The parsing code snippet is:
    Document doc = null;
    DocumentBuilderFactory dbFactory = null;
    dbFactory = DocumentBuilderFactory.newInstance();
    dbFactory.setNamespaceAware(true);
    DocumentBuilder db = dbFactory.newDocumentBuilder();
    db.setEntityResolver(new LogDTDResolver());
    doc = db.parse(is);  // is is an InputStreamAnyone have a clue? Is there a property I am missing. I have searched for the complete set of jaxp properties, but I can't find one.
    Thanks for any help.

    So it looks like log4j is doing its own parsing and it requires the DTD. Don't know how (or why) it does that.
    You call the setOutputProperty() method of the Transformer. This is designed to configure the Transformer with properties that are normally set in the <xsl:output> element of an XSL transformation. The properties you need are "doctype-system" and maybe "doctype-public".
    You're quite right, it isn't obvious. That's what happens when systems are designed by architects who believe in abstraction too much.

  • Creating new tags slow in Mac OS Yosemite

    Hi
    I have been finding creating new tags in Mac OS X Yosemite to be really slow. Whilst it was slow in Mavericks, it really is taking a lot of time now. Using previously created tags is not a problem.
    Has anybody else found this, and a solution for it?
    With Thanks

    My searching on this issue, which I had too, lead me to a solution. The problem is described and the solution outlined in the following posting:
         http://apple.stackexchange.com/questions/146322/creating-and-modifying-tags-hang s-finder-in-os-x-10-9-mavericks
    I think the issue isn't just in Yosemite, but seems to have got worse with that upgrade, but this fix worked for me, and it might for you too.

  • I want to create new tags.

    I often access science sites. Today I tried to bookmark such a site and wanted to tag it with a tag called "Science" and was unable to find that tag so now I want to create a tag called Science. How do I do that? Firefox is supposed to be personalizable and it's why I run it. Is a folder the same as a tag? I saw info on how to create new folders but not tags. Please help.

    See [[Bookmark Tags]]

  • Ignore DOCTYPE tag in xml

    Hi!,
    I need to remove DOCTYPE tag from the xml file. The parser is trying to validate the DTD. I do not want to validate, I just want to parse. I could not find any documentation on how this can be done. if any one of you have done this please let me know how you have managed to ignore the DOCTYPE tag.
    Regards

    Here is one way to do it:
    Example taglib DOCTYPE:
    <!DOCTYPE taglib
    PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
    "http://java.sun.com/dtd/web-jsptaglibrary_1_2.dtd">
    Example Code:
    // Get your parser, then set its EntityResolver to your own custom er.
    parser.setEntityResolver(new EntityResolver()
    public InputSource resolveEntity(String publicId, String systemId)
    if ("-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN".equals(publicId))
    return new InputSource(
    new ByteArrayInputStream("<?xml version='1.0' encoding='UTF-8'?>".getBytes()));
    else
    return null;
    });

  • How can I create Object Tag which supports Sun and MS JVM both.

    Hi,
    I have created object tag as shown below
    <object classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93"
    name = "TestApplet" height="0" width="0" >
    <param name="code" value="com.apps.TestApplet.class" />
    <param name="codebase" value="codes" />
    <param name="archive" value="TestApplet.jar" />
    </object>
    The above tag is working fine with the below JVM combinations in Windows XP.
    1) Only Sun JVM
    2) Only MS JVM
    3) Sun JVM & MS JVM
    But these conditions are not working with Windows 2000.
    How we can create object tag which will support for these two opertating systems?

    I am not able to understand the problem. From my understanding, you have an applet which you are trying to display in a browser using <object> tag. If that is the correct then all it matters is the browser and the JRE�
    For example the below code when put in a JSP or a HTML, will use JRE 1.6.0_01 that is available on the client machine. If that is not available on the client machine then it will try and download automatically in IE.
    This below code is for IE� if you are using Mozilla Firefox then you need to change the �classid� attribute to �java: com.foo.bar.ui.MyClass�
    <OBJECT ID="Gantt" classid = "clsid:CAFEEFAC-0016-0000-0001-ABCDEFFEDCBA"
                  codebase = "http://java.sun.com/update/1.6.0/jinstall-6u1-windows-i586.cab"
                  WIDTH = "980" HEIGHT = "495" ALIGN = "baseline">
                   <PARAM NAME="cache_option" VALUE="Plugin">
                  <PARAM NAME ="CODE" VALUE = "com.foo.bar.ui.MyClass" >
                  <PARAM NAME="MAYSCRIPT" VALUE="true">
                  <PARAM NAME ="cache_archive" VALUE = "Myjar.jar /" >
                  <PARAM NAME = "type" VALUE = "application/x-java-applet;jpi-version=1.6.0">
                  <PARAM NAME = "scriptable" VALUE = "false">
                  <strong>
                     This browser does not have a Java 1.6.0_01 Plug-in.
                     <br />
                     <a href="http://java.sun.com/update/1.6.0/jinstall-6u1-windows-i586.cab">
                       Get the latest Java Plug-in here.
                     </a>
              </strong>
            </OBJECT>

  • How to create own tags in JSF?

    I am using xhtml, So I need to create own tags for retrieving data from database & query for data. So Just explain me the procedure for doing so. I m using hsql database...
    Thanking you
    --Mansingh Shitole                                                                                                                                                                                                                                                                                                                                                                                                                           

    ms_shitole wrote:
    I am using xhtml, So I need to create own tags for retrieving data from database & query for data. So Just explain me the procedure for doing so. I m using hsql database...It sounds to me that 1) using are using Facelets and 2) you are looking for a replacement for the JSTL SQL tags. If this is the case, I'll quote the J2EE Tutuorial:
    http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JSTL7.html says:
    The JSTL SQL tags for accessing databases listed in Table 14-8 are designed for quick prototyping and simple applications. For production applications, database operations are normally encapsulated in JavaBeans components.

  • Label Studio - Create a tag file as a pdf

    I am attempting to create a tag file as a pdf file in label studio.  When I attempt to use Adobe Acrobat, I get a message that says that "font WASP128M could not be embedded because of licensing restrictions."  Business Objects suggested trying another software to create the pdf file.   I downloaded Pdf Creator,  it creates a pdf file, but there is nothing in it.   Does any one have any ideas on how to do this?  Thanks for the help.

    Chris,
    Have you tried using one of the following pdf printer drivers?
    Here is some info from our KB article:
    There are many companies that offer PDF printer drivers. SAP BusinessObjects is not affiliated with any of these companies and does not recommend one in particular. The below information may change without SAP BusinessObjects knowledge. Here is a list of several PDF printer drivers and where to find them:
    - PDF Factory is from FinePrint Software, it can be found at http://www.fineprint.com/index.html
    - Freeware PDFCreator is a freeware PDF print driver, it can be downloaded from http://sourceforge.net/projects/pdfcreator/
    - Win2PDF is from Dane Prairie Systems, Inc. and can be found at http://www.win2pdf.com/
    I think Larry and I found that there are some issues with the latest version of PDFCreator but the other two should work fine.
    Thanks,
    Kendra

  • Is it possible to create "places" tags without the maping feature?

    Is it possible to create "places" tags without the maping feature? I updated from PSE 10 (where I created my own list of "places,") to PSE 12, where "places" seems to require the mapping feature. I would prefer not to use the map, and stick to my old way.
    Thanks for any help!
    Tom

    Apparently, not only is the mapping feature required, but once the GPS-loaded Place tag is created, it is not listed in alphabetical order with other place tags.  It is listed by country, then by state, then by title!!  !! VERY irritating!!  And what if I want to create a place tag (of which I already have many) which does not have a recognizeable address, like, say, Grandmother's House?  VERY irritating.
    And if I use the Keyword feature to create Place tags, they will be in an entirely separate list from the other Place tags.  VERY irritating!
    Who designed this upgrade?  I will soon start looking for an alternative, though I have used Photoshop Organizer for years and have thousands of photos in it.  My upgrade to PSE 12 has caused me nothing but headaches.

  • Generating !DOCTYPE tag for a Document

    I am using the SDK JAXP implementation of DOM to parse a simple XML document containing a !DOCTYPE tag, make a minor modification and write it back to a file. All works fine except that the !DOCTYPE tag is not written to the StreamResult by the Transformer.
    getDoctype() on the Document does return a Doctype object that was parsed, but it's not written when transforming the Document into a StreamResult.
    How do I write the !DOCTYPE tag into the output?
    Please help.
    Nikhil

    Set DOCTYPE_SYSTEM output property.
    TransformerFactory tFactory = TransformerFactory.newInstance();
    Transformer transformer = tFactory.newTransformer();
    transformer.setOutputProperty(javax.xml.transform.OutputKeys.DOCTYPE_SYSTEM, "exampleDtd.dtd");

  • DOCTYPE tag above CF's form validation javascript

    Hi,
    CF 8 seems to put the form validation javascript at the very top of the page, even before the HTML tag and the DOCTYPE validation tag.  This is causing problems with my style sheet.  Do you know of a way I can (at the very least), put my DOCTYPE tag above the javscript that CF renders?
    Thank you,
    David
    <script type="text/javascript" src="/CFIDE/scripts/cfform.js"></script>
    <script type="text/javascript" src="/CFIDE/scripts/masks.js"></script>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">

    Include the head tag, to entice Coldfusion to put the script tags there. Something like this
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head><title>test page</title></head>
    <body >
    <cfform>
    </cfform>
    </body>
    </html>

  • Problem with DOCTYPE tag in the index.html for flex file

    When I have the following !DOCTYPE tag in the index.html file I use to load the flex swf file(s) both FireFox and Orical browsers both become horizontally shortened.  When the tag removed everything works fine.  Given that the !DOCTYPE tag is necessary for good html I'd really like to know what's going on.
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

    Good info on that site about HTML, unfortunatly it had nothing new for me.  I did double check and everything and I was doing things the way they recomend.
    I'm really bothered that this is happening.  The DOCTYPE tag should be used and it should not have this effect when added to the HTML generated by the Flex Builder.  Additionally the new Flash Builder does have the DOCTYPE tag in its generated HTML and this is very worrisome.

Maybe you are looking for