Include in XML style

I am trying to convert some JSP files to an XML style.
This is a snip from taglibs.jsp:
<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
xmlns:bean="http://struts.apache.org/tags-bean"
xmlns:bean-el="http://struts.apache.org/tags-bean-el"
xmlns:myapp="/WEB-INF/myapp.tld"
version="1.2">
<jsp:directive.page language="java" errorPage="/error.jsp" pageEncoding="UTF-8" contentType="text/html;charset=utf-8" />
<html:xhtml />
</jsp:root>
The problem is that I can't find a way to include it in other JSP pages.
The following obviously doesn't work.
<jsp:root
xmlns:jsp="http://java.sun.com/JSP/Page"
version="1.2">
<jsp:directive.include file="/common/taglibs.jsp" />
</jsp:root>
Any suggestion?
Marcello

How about using the jsp:include instead of the jsp:directive.include? Is there a reason you need the static include (the directive), or are you able to just include the finished product of the included JSP(the jsp:include)?
<jsp:include page="/common/taglibs.jsp"/>

Similar Messages

  • Can the XML style sheet be embedded in the report file?

    My customer would like to be able to share test reports with several locations. The problem is that sending just the XML report file is not enough. The report file points to a style sheet that must exist at the specified path on the destination PC. It creates problems when one simply wants to email over a test report. I have customized the style sheet slightly to make things easier to read. So, can I embed my custom style sheet in each report file?
    Thanks,
    Daniel L. Press
    PrimeTest Corp.
    www.primetest.com

    Hi,
    The XML style sheet should not be embedded into the report file. Since XML would represent raw data, you would not include information on how to interpret it. However, there is a way for you to easily reference your style sheet, even when it is on another computer.
    1) Go to Configure >> Report Options in TestStand, and change the style sheet file to your style sheet.
    2) Uncheck the "Store Absolute File Path" box.
    3) Make sure the style sheet is in the same folder as your report.
    You can view this on any computer, and now a relative path is now being used to reference the file.
    Allen P.
    NI

  • What is the best way to include an xml file in JSP?

    I have a jsp page that I need to include an xml file. The xml file
              uses an xsl to render the file. What is the best way to include the
              xml file and still maintain the structure of the style sheet?
              Thanks
              Jennifer
              

              The best way is using the tag lib. If you cannot, but you can use JAXP, you can
              try
              javax.xml.transform.Transformer.transform(Source xmlSource,
              Result outputTarget)
              throws TransformerException
              You construct the transformer with you xsl, use you xml file or DOM to form xmlSource,
              and use JSPWriter "out" to form outputTarget (StreamResult). But if your JSP page
              generates the xml itself, tag lib is the only way.
              [email protected] (Jennifer) wrote:
              >[email protected] (Jennifer) wrote in message news:<[email protected]>...
              >> I have a jsp page that I need to include an xml file. The xml file
              >> uses an xsl to render the file. What is the best way to include the
              >> xml file and still maintain the structure of the style sheet?
              >>
              >> Thanks
              >>
              >> Jennifer
              >
              >Or is there a way to parse the xml file with the jsp page to display
              >the information. I cannot use the Java Standard Tag Libraries as the
              >version of iplanet we are running does not support the JSTL
              >
              >Thanks
              >
              >Jennifer
              

  • How to include  % in xml document element

    I am not able to figure how to include % in xml elements
    ex:
         <ITEM> 90% of people</ITEM>

    The error message suggests that the % is not in a text node, like your example, but in an element name -- where it is not permitted. Perhaps you could post the actual XML document that causes the error, or at least the part of it that contains the % character.

  • Whitespace in XML-Style JSP

    Hi,
    I am having a slight issue with the XHTML content generated by a JSP. The output is stripped entirely of all whitespace, such that the content is all on one line. I have a request from one of our content writers to view the source "nicely". Oddly, in all of my searches for this problem, I have found people experiencing the opposite problem.
    Suppose I have a JSP like so:
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
    <jsp:directive.page language="java" contentType="text/html;charset=ISO-8859-1"/>
    <html>
    <head>
         <title>A JSP Page</title>
    </head>
    <body>
         <table>
              <tr>
                   <td>Table Cell</td>
              </tr>
         </table>
    </body>
    </html>
    </jsp:root>The resulting output is:
    <html><head><title>A JSP Page</title></head><body><table><tr><td>Table Cell</td></tr></table></body></html>How can I get the output to have the same indentation as the source?
    I am using Tomcat 4.1.29.
    Thanks!

    Hi Syed,
    Try these links:
    <a href="http://www.javaranch.com/newsletter/Feb2002/xmljsp.html">Exploring JSP Documents (XML Style JSP Pages)</a> --> an excellent overview of the benefits of JSP Documents (XML Style JSPs) over standard JSP Pages.
    <a href="http://www.webmonkey.com/webmonkey/01/22/index3a.html?tw=programming">Intro to JSP</a>
    You can also try googling for "XML Style JSP"...
    Regarding books on JSP 2.1 and Servlet 2.5 -- I really can't believe that there are none available! Have you tried searching on amazon?
    HTH!
    -Vladimir

  • Include another xml file in web.xml

    I was able to use XML Entity to include another xml file in web.xml for older servlet specifications, i.e.:
    <?xml version="1.0" encoding="ISO-8859-1"?>
    <!DOCTYPE web-app
        PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
        "http://java.sun.com/dtd/web-app_2_3.dtd" [
      <!ENTITY my-web SYSTEM "my-web.xml">
    ]>
    <web-app>
      &my-web;
    </web-app>This allows me to share my-web.xml among various web applications.
    How do I achieve the same thing for servlet specification 2.5, which does not have a DTD but rather an XSD?
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns="http://java.sun.com/xml/ns/javaee"
      xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
      id="WebApp_ID" version="2.5">I am using Glassfish V2UR1. I know about $domain-dir/config/default-web.xml, but for reasons I won't get into I cannot put things in there.

    Hi Maksim. I understood that. It's just that I would prefer some method that doesn't require the developers to do something like extracting a file from the EAR file, changing the file and then putting it back in. As you probably know, some developers could handle it and some will most certainly make mistakes.
    When they do they come to my group and say "my app doesn't work" and then we have to spend time figuring out why.
    Plus, once the developers get used to doing things the automated way they're going to have a hard time remembering to do a manual step each time they do a build.
    I have heard that there may be some way to do something similar to this on Visual Administrator. I'm going to investigate that too.
    Thanks!
    David.

  • XML Style sheet

    Does anyone know how to create xml style sheet from oracle report. Or is it possible thru the tool ?
    Please let me know.
    Thanks
    Rakesh

    You will need to check a few things:
    a) Check that the Integration Option in the HFM Adapter "FDM WEB SERVER NAME" matches the value that the users are using to access FDM.
    http://<fdmwebservername>/HyperionFDM
    Make sure that the server host name is entered into this option.
    b) Check that the XML file type on the users workstation is configured to open with Internet Explorer and not the XML Editor.  You can do this by creating a text document named test.xml and right-clicking on it and choose "properties" and update the program to open the file to Internet Explorer and save.
    c) Make sure that the FDM Web Site is in the users trusted sites in the IE Browser
    d) Make sure that the "Automatically prompt for file downloads" and "Automatically Prompt for Active-X Controls" options are set to Enabled in the IE Settings.

  • [svn:fx-trunk] 13383: Modify to include the xml header (with encoding) in the DITA xml files.

    Revision: 13383
    Revision: 13383
    Author:   [email protected]
    Date:     2010-01-08 12:04:00 -0800 (Fri, 08 Jan 2010)
    Log Message:
    Modify to include the xml header (with encoding) in the DITA xml files.
    QE notes: None.
    Doc notes: None
    Reviewed By: Pete
    Tests run: checkintests
    Is noteworthy for integration: No
    Modified Paths:
        flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/asdoc/TopLevelClassesGenerator.ja va

    Thats good news.

  • Flex 4, exporting a Release Build does not include CSS/XML?

    Hello
    So I'm using external CSS and XML. I'm pulling the CSS with <fx:Style source="CSS/styles.css" /> and am using HTTPService to fetch the XML data.
    It works great, until I export as a Release Build.
    It doesn't include the CSS or XML files, but still pulls the CSS colors and whatnot, I just can't update them.
    What gives? How can I get the CSS and XML external files to.. well, stay "external"?
    I need the user to be able to update the CSS and XML on their end, but can't if the Release Build embeds the CSS and XML files before exporting..
    Any help would be appreciated, thanks!

    dont think Flex can read a raw CSS sheet. You have to precompile them, right click on the file in project explorer and chose compile CSS to SWF
    http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf69084-7f8c.html

  • Variable not being included in XML data file output

    This seems like it should be obvious, but I've struggled with this for a couple of days.
    As a programming principle, I like to make the form as "smart" as possible and the resulting Word templates, or XML documents as simple as possible. I need to be able to set a "flag" that would be in the XML data file if certain conditions are met, e.g.,
    if (field1.rawValue == "0"){variable1 == "1"};
    if (field2.rawValue == "0") {variable1 == "1"}; etc.
    The problem that I'm having is that I can't seem to get variable1 to be included in the XML data file that the form creates.
    Help! This seems like it should be so simple but I'm baffled.
    Bill

    The variable you're setting does not fall within the scope of the xml output (it's scope is only within the execution of the form).
    Try creating a variable (Using File > Form Properties >Variable) and assigning your value to it (variableName.value = 1).
    One note of warning, you'll want to trigger the validation event every time the form is opened or your value will return to the default value when users re-open the form.

  • How to include an xml file in an xml file ?

    Hello,
    Is there an xml tag to include the content of an xml file in another ? So the parser, parsing the first one, automaticaly parse the second one (included one) when reaching the tag.
    Thanks.
    William T.

    You can use an entity reference to point to the next xml file.
    An entity reference in an xml file is preceded by the & And then the name of the reference i.e.
    <mytag>&nextFile</mytag>. Your DTD for the xml file must have a corresponding <!ENTITY> tag that says how to dereference the entity reference in the xml file to an actual resource. If you want to handle entity references via a SAXParser, then you will need to implement the EntityResolver interface and register this with the parser. I think it should be possible in the entity resolver to create a new parser object to handle the new file.
    Hope this helps.

  • XML style sheet error at Validate step in FDM for few locations

    Hi All,
    Users are facing the "XML page cannot be displayed - The style sheet doesnot contain a document element. The style sheet may be empty, or it may not be weel-formed XML document.." for very fre locations while validating the data.
    Please advise as it is most annoying thing for users.
    Thanks and Regards

    You will need to check a few things:
    a) Check that the Integration Option in the HFM Adapter "FDM WEB SERVER NAME" matches the value that the users are using to access FDM.
    http://<fdmwebservername>/HyperionFDM
    Make sure that the server host name is entered into this option.
    b) Check that the XML file type on the users workstation is configured to open with Internet Explorer and not the XML Editor.  You can do this by creating a text document named test.xml and right-clicking on it and choose "properties" and update the program to open the file to Internet Explorer and save.
    c) Make sure that the FDM Web Site is in the users trusted sites in the IE Browser
    d) Make sure that the "Automatically prompt for file downloads" and "Automatically Prompt for Active-X Controls" options are set to Enabled in the IE Settings.

  • Including an XML file

    Hi,
    I have a simple question:
    Is it possible for the users to include XML files?
    Situation:
    A user sends out 6 PDF Forms, after filling out he receives it again and needs it to include in his PDF form.
    Thank you for your help
    Carsten

    As far as I know, you only can import xml-files with Adobe Acrobat. If you use it, choose "Extended" -> forms -> "importing data"
    I don't know the exact names because I just know it from the German version.
    Good Luck

  • Include in XML Code

    I'm not a XML guru and the only way I found to "include" a fixed xml part (in order to avoid to repeat it many times) is the & wich refers to an ENTITY in the DTD wich poins to an external file.
    Sometime, however, the DTD can't be changed.
    Could someone suggest me a workaround for that problem ?
    TIA
    Tullio

    You can have internal DTD to specify the entities:
    e.g.
    &lt;?xml version="1.0"?&gt;
    &lt;!DOCTYPE foo SYSTEM "D:\jiwang\work_oracle\xml_sample\xmlparser\java\dom_dtd\test03.dtd" [
    &lt;!ENTITY sig "Jinyu" &gt;
    ]&gt;
    &lt;foo quux="This is quux"&gt;
    This is &sig; foo
    &lt;/foo&gt;

  • Can I convert my .xml style mappings to an .isf?

    Hi, everyone,
    I'm test driving TCS2 which has RH8.  In RH7, style mappings were saved as .xml files.  It appears that in RH8 they are saved as .isf files.  We spent a lot of time on style mappings and would like to reuse them.  Is there anyway that I can convert the file in some way? I tried just changing the file extension, but RH didn't like it.
    Thanks.

    I don't have an isf extension yet.  I just have an .xml file that I want to convert to an .isf so that I can use it in RH8.
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Mary K. Greer
    Information Developer - Learning Management Solutions
    Intelligent Automation Solutions Client Services
    407.771.8187

Maybe you are looking for

  • Erro na comunicação SEFAZ AM - Ambiente de Produção

    Bom dia Srs, Estou com problemas de comunicação com a SEFAZ AM, ambiente de produção. No "Service Status", mostra o ambiente de produção com erro 70, desde o dia 01.10.2010. Entrei em contato com a SEFAZ AM e eles dizem que não tem problema do lado d

  • Include another web page content

    Hi All, I'm currently looking for a new job, but there are sooooo many job sites. I want create a .jsp to go to all the different sites and select the "search" for me to show it all in one big page. eg. If I pass it this string "http://forum.java.sun

  • Is Copy Paste Pans & Zooms Possible in Photoshop Elements Slide Show Editor Slideshow?

    In the Photoshop Elements Slide Show Editor, someone wants to create a unique pan and zoom effect for one photo and be able to apply it the the rest of the photos in the Filmstrip without having to do that on an individual photo basis. In the Slide S

  • Color/tone of photo changes when printing...

    I'm trying to print a photos for an invitation, its a black and white photo with a pink background.  The black and white levels have been adjusted to a very light tone since I have to put vellum paper on top with the invitation wording... When I send

  • TimeStamp Errors on Guided Procedures

    Hi, i currently create a GP process where the PDF can call the web service and add to the database. currently i have a startDate and endDate inside PDF the objectType for it is Date but then my web service, i try to deploy the methods by casting the