XSLT to create JSP Document

In the JSP 1.2 spec it talks about using XSLT to generate JSP Documents. I'm not sure if it's talking about generating JSPs at design time or run time. Has anyone attempted creating them at runtime? I've looked around and haven't found anything addressing this. If anyone has done this or has a link to somewhere that talks about this I'd appreciate any direction you can give.
Thanks.

Thank you for the reply but I don't think this addresses my issue. I understand how to use XSLT, XML, and JSP. What I'm looking for is the process of creating JSP Documents at runtime using XSLT. What part of the servlet cycle is this supported so that I can generate a JSP Document and then immediately use it? Is that inherently supported in J2EE?

Similar Messages

  • Problems with JSP Documents (XML Mode)

    Hi --
    Have been following the spec for JSP as XML documents because I want to produce JSPs using XSLT. Two problems which I've yet to find anything but workarounds for:
    1. (Most pressing) JSP Documents do not allow this <%= blah %>. This creates problems when I want to dynamically create an attribute value. The spec recommends this: 'value = "%=var%"', but I've tried this in Tomcat 4.1.12 and the expression gets reproduced literally at run-time. I've searched these forums and not found an answer.
    2. Transformer wigs out on colons in "jsp:root" or "c:out" because it signifies a namespace with which it is unfamiliar. It doesn't need to recognize the namespace. Right now I'm putting in placeholders (jsp999root, for example) and replacing them after processing. Is there a better way?
    These problems are really getting in the way. Any help would be most appreciated.

    Have been following the spec for JSP as XML documents because I want to
    produce JSPs using XSLT. Two problems which I've yet to find anything but
    workarounds for:
    1. (Most pressing) JSP Documents do not allow this <%= blah %>. This creates
    problems when I want to dynamically create an attribute value. The spec
    recommends this: 'value = "%=var%"', but I've tried this in Tomcat 4.1.12 and
    the expression gets reproduced literally at run-time. I've searched these
    forums and not found an answer. I am stuck on this also and desperately searching for an answer. Has anyone found anything yet?
    2. Transformer wigs out on colons in "jsp:root" or "c:out" because it
    signifies a namespace with which it is unfamiliar. It doesn't need to
    recognize the namespace. Right now I'm putting in placeholders (jsp999root,
    for example) and replacing them after processing. Is there a better way?You can (and should) put multiple namespace declarations in the xsl:stylesheet tag. that will let it know about jsp:* and pass it through appropriately. Try something like:
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:jsp="http://java.sun.com/JSP/Page">

  • Creating a Document from an uploaded file

    Hi,
    I'm trying to create a Document through a JSP, from a file already on the local hard drive. The line that is causing the error in the JSP is:
    Document doc = ifs.createDocument( "createdoctest", new FileInputStream("D:\\oracle\\ora81\\ifs1.1\\jws\\public_html\\upload\\test.txt" ), ".", null, false, null );
    I'm basically trying to copy the file test.txt into the iFS repository by creating the Document.
    The error is:
    oracle.ifs.common.IfsException: IFS-30002: Unable to create new LibraryObject
    What have I done wrong here?
    Thanks!
    null

    Hi,
    I tried your code and it worked for me.
    below is my code
    FolderPathResolver fpr = new FolderPathResolver(ifSession);
    IfsFileSystem ifsFile = new IfsFileSystem (ifSession);
    PublicObject pObject = fpr.findPublicObjectByPath("/home/user");
    if (pObject != null){
    Document doc = ifsFile.createDocument( "createdoctest", new FileInputStream("C:\\Temp\\application.pdf"), ".", null, false, null );
    doc.setOwner( pObject.getOwner() );
    Good luck
    Suresh

  • Howto optionally include an attribute on an element in a JSP document ?

    I cannot find a way to optionally include an attribute on an element in a JSP document (JSPX). My JSP document is used to create an XML according to an XML schema where some element are declared as optional by the schema (default for element attributes).
    I've tried:
    a)
    <elem <c:if test="${!empty obj.attr}">attr=${obj.attr}</c:if>>
    </elem>b)
    <jsp:element name="elem">
       <c:if test="${!empty obj.attr}">
          <jsp:attribute name="attr">${obj.attr}</jsp:attribute>
       </c:if>
       <jsp:body>
       </jsp:body>
    </jsp:element>And none of them work. Any ideas?

    I cannot find a way to optionally include an attribute on an element in a JSP document (JSPX). My JSP document is used to create an XML according to an XML schema where some element are declared as optional by the schema (default for element attributes).
    I've tried:
    a)
    <elem <c:if test="${!empty obj.attr}">attr=${obj.attr}</c:if>>
    </elem>b)
    <jsp:element name="elem">
       <c:if test="${!empty obj.attr}">
          <jsp:attribute name="attr">${obj.attr}</jsp:attribute>
       </c:if>
       <jsp:body>
       </jsp:body>
    </jsp:element>And none of them work. Any ideas?

  • Automatically populate fields in jsp documents based on other fields

    hello guys. I have a jsp document
    that has the following
    <af:inputText value="#{bindings.SourceDocumentId.inputValue}"
    label="#{bindings.SourceDocumentId.label}"
    required="#{bindings.SourceDocumentId.mandatory}"
    columns="#{bindings.SourceDocumentId.displayWidth}"
    binding="#{backing_transactions_editTransactions.docId}"
    id="docId">
    <af:validator binding="#{bindings.SourceDocumentId.validator}"/>
    <f:convertNumber groupingUsed="false"
    pattern="#{bindings.SourceDocumentId.format}"/>
    </af:inputText>
    <af:inputText value="#{bindings.DocumentName.inputValue}"
    label="#{bindings.DocumentName.label}"
    required="#{bindings.DocumentName.mandatory}"
    columns="#{bindings.DocumentName.displayWidth}"
    binding="#{backing_transactions_editTransactions.docName}"
    id="docName">
    <af:validator binding="#{bindings.DocumentName.validator}"/>
    </af:inputText>
    And I have created the generated the backing beans automatically.
    public class EditTransactions {
    private CoreInputText docId;
    private CoreInputText docName;
    public CoreInputText getDocId() {
    return docId;
    public void setDocName(CoreInputText inputText7) {
    this.docName = inputText7;
    public CoreInputText getDocName() {
    return docName;
    I have a method in appmodule that has this
    public String getDocName(Number docId)
    {String docName;
    return docName
    on the document Id field I have to input a certain docId after I input the docId I have to populate automatically the docName based on the doc Id being given.
    question
    1. how can I set the document name automatically w/out submitting the page ?
    2. how can I use my backing bean to set the docName using the method in my AppModule.?
    Can anyone help me regarding this one.
    Thank in advance
    alvin.

A: automatically populate fields in jsp documents based on other fields

here is what you need to do:
1. Change the definitions for your fields as following
<af:inputText value="#{bindings.SourceDocumentId.inputValue}"
                        label="#{bindings.SourceDocumentId.label}"
                        required="#{bindings.SourceDocumentId.mandatory}"
                        columns="#{bindings.SourceDocumentId.displayWidth}"
                        binding="#{backing_transactions_editTransactions.docId}"
                        id="docId" valueChangeListener="#{backing_transactions_editTransactions.docIdChange}"
autoSubmit="true">
            <af:validator binding="#{bindings.SourceDocumentId.validator}"/>
            <f:convertNumber groupingUsed="false"
                             pattern="#{bindings.SourceDocumentId.format}"/>
          </af:inputText>
          <af:inputText value="#{bindings.DocumentName.inputValue}"
                        label="#{bindings.DocumentName.label}"
                        required="#{bindings.DocumentName.mandatory}"
                        columns="#{bindings.DocumentName.displayWidth}"
                        binding="#{backing_transactions_editTransactions.docName}"
                        id="docName"
partialTriggers="docId">
            <af:validator binding="#{bindings.DocumentName.validator}"/>
          </af:inputText>2. add the followig method to your backing bean:
  public void docIdChange(ValueChangeEvent valueChangeEvent) {
    getDocName().setValue((String)getDocId().getValue() + "suffix");
  }Run your form and enter the value into docId field, then press tab to go to the next field - docName will be populated

here is what you need to do:
1. Change the definitions for your fields as following
<af:inputText value="#{bindings.SourceDocumentId.inputValue}"
                        label="#{bindings.SourceDocumentId.label}"
                        required="#{bindings.SourceDocumentId.mandatory}"
                        columns="#{bindings.SourceDocumentId.displayWidth}"
                        binding="#{backing_transactions_editTransactions.docId}"
                        id="docId" valueChangeListener="#{backing_transactions_editTransactions.docIdChange}"
autoSubmit="true">
            <af:validator binding="#{bindings.SourceDocumentId.validator}"/>
            <f:convertNumber groupingUsed="false"
                             pattern="#{bindings.SourceDocumentId.format}"/>
          </af:inputText>
          <af:inputText value="#{bindings.DocumentName.inputValue}"
                        label="#{bindings.DocumentName.label}"
                        required="#{bindings.DocumentName.mandatory}"
                        columns="#{bindings.DocumentName.displayWidth}"
                        binding="#{backing_transactions_editTransactions.docName}"
                        id="docName"
partialTriggers="docId">
            <af:validator binding="#{bindings.DocumentName.validator}"/>
          </af:inputText>2. add the followig method to your backing bean:
  public void docIdChange(ValueChangeEvent valueChangeEvent) {
    getDocName().setValue((String)getDocId().getValue() + "suffix");
  }Run your form and enter the value into docId field, then press tab to go to the next field - docName will be populated

  • Acrobat Pro version 8 doesn't create pdf documents using Windows 7

    I run Windows 7 on my PC and have installed Acrobat Professional 8.  When I try to create a pdf (or using the pdf printer), it just hangs up and won't create the document.  Any fixes for this?
    Thanks.

    You likely have a 64-bit system. Do the updates and you might be successful. Several folks have reported success on 32-bit Win7 installations and a few with 64-bit systems. However, the updates are critical. If you have trouble doing the updates from the help menu, use http://www.adobe.com/support/downloads/product.jsp?product=1&platform=Windows and install the updates in order (a few can be skipped and you can note those by downloading from the most recent that tells the previous version required). You can also save time by rebooting only after the last update.

  • JSP Documents (JSP pages in XML format) and Namespaces

    I have 1 set of XSLT stylesheets that takes XML and outputs JSP documents.
    This 1 set of XSLT supports numerous clients (customers).
    I have a new customer that uses a new namespace, let's call it "xyz".
    This namespace is the TLD for xyz custom tags.
    So, it would look something like this in the resulting jsp:root tag --> xmlns:xyz = "/xyzTagLib".
    Where /xyzTagLib has a corresponding entry in web.xml that points to the xyz.tld that is delivered in WEB-INF/TLD.
    However, most customers do not have the xyz application installed.
    Thus, I added the exclude-namespace-prefixes="xyz" in the xsl:stylesheet tag to conditionally add the xmlns:xyz only if an xyz tag exists. However, this does not add it to the jsp:root tag, but only to each individual xyz tag in the resulting document.
    However, the resulting JSP does not work in the runtime environment because it does not recognize the xyz tags.
    Is there a known bug with jsp documents declaring namespaces "in line" instead of at the jsp:root level? Is there a way around this?
    Thanks,
    Brian

    Hi Tridib,
    the XML content is stored in the .xml file. You'll have to access it in a way that doesn't cause the XML-to-HTML transformation to take a peek at the format. You could probably do this by accessing the repository in question via WebDAV. If you're on a later SP, you should be able to go to /irj/go/km/docs/ in your browser to access the repository via WebDAV. Otherwise, take a look in the details pane of the folder that contains the .xml file in question. Under properties, there'll be a URL to access the folder via WebDAV.

  • Help in creating XML documents in ABAP using XI in new version ECC6.0

    Hello All:
       I am pretty comfortable with XML and XSLT but new to XI. Is there a way of creating XML documents in ABAP using XI in new version ECC6.0? Please provide me with any links or any information you may have. All the answers will be rewarded.
    Thanks.
    Mithun

    hi,
    U cant create XML data in ABAP.
    to send the data to the XI, u have to use the IDOC or RFC FM, from there IDOC or RFC adapters will read the data in the same  format  and these adapters will convert the data in to  XML .Bcoz XI understand only XML data.
    from there XI will process and route them to Destination, by using anthor adapter.
    here u can use file adapter if u want data in file foramat from the IDOC or RFC .
    So XI is the integration tool only.
    reward points if helpful
    ragards
    sreeni

  • JDev 1014 JSF: difference between JSF JSP Page and JSF JSP Document ?

    Hi all here ;)
    I've been using the new JDev 1014 for some days now, find it very useful, but still... the help docs are not very helpful in one (minor) point: when you create a new JSF JSP item, you have to select either "JSP Page" or "JSP Document". Now, I see the difference in the created code, but what's the difference in it's usage?
    thanx in advance
    Thomas Nagel

    Thomas,
    there is none. Its just that the document has an XML format and the page is a typical JSP page. Its nothing specific in JDeveloper and just a matter of taste I guess.
    Frank

  • How to create a document/report on all objects in the BW system?

    Hi,
    The requirement in our company is to create a document/report with the list of all the objects that exist in the BW system for various applications. This list should contain the technical details of the different objects and where an object is used, what's the source for the object etc. The information should be similar to that in the Metadata repository but it should be one single document/report which includes all the objects.
    I tried using the 0TCTBWOBJCT info object (content browser) but it was not of great help.
    Can anyone help me out in this task?
    Thanks,
    Anu

    Hi,
    Try to use tables RSOSFIELDMAP, RSDSSEGFD and RSTRAN
    Hope it helps
    bhaskar

  • Error while creating a  Document  in CV01N

    Hi Gurus,
    I am trying to  create  a document through CV01N and  i wnat to attach it to material .
    We have created some Z- Document types and  the  origin for  the  file(source) is picked up from another system.
    Suddenly iam creating an error  File extension type XX  not   allowed  for  work station PDF.
    I can able to  pickup  documents from my Desktop, but  when i try to pull it from the  document  management system by mentioning the URL it  showing me the above error.
    Users are able to create  by  specifying the URL path till last week.But this week they are  facing the above problem
    Can anybody  have any idea of where we missing or  what the error is. Suitable answers will be rewarded
    Thanks in advance
    Regards
    Venkat

    Hi,
    I am newly using BI publisher . I am using 10.1.3.4.0 . I am just trying to create a report in test name. that is the first step to create a report where i am getting error. I am using default RPD paint , where all the user and Groups are defined .

  • Error while creating delivary document

    Hi
    i got error while creating delivary document
    "Delevivary documents could not be created"
    Thanks&regards
    kishore kumar

    Hi Kishore,
    Please check the sales order is this relevent for the delivery or not.
    Check the copy control settings between your sales document type and delivery document type in VTLA transaction.
    Check the incompletion log for the sales order.
    I hope it will help you,
    Regards,
    Murali.

  • I created a document in Pages on my ipad and now it won't open up. How can I fix this?

    I created a document on my Ipad and when I finished it, I closed Pages. When I went to re-open Pages and see the document it wouldn't open. I click on the document and it shows the processing symbol but then the entire program closes. All of the other documents within pages open up fine, just not this one. Any help?

    Try resetting your iPad.  Hold the on/off and home buttons together for 7 or 8 seconds till the Apple logo appears.
    I'm assuming your default is to save Pages documents to iCloud, and that you had a good WiFi connection when you closed Pages the last time you tried to save the document.

  • Program does not create PCP0 documents for TMS Idocs

    Hi All,
    We have a dialy job that will catch up all payroll/tms idocs that is being received by the system. The program will automatically creates a document in the tcode PCP0 for every idocs that it has gathered both Idocs that have no errors and Idocs that have errors. Would like to ask if you have experienced the cause of this?
    Regards,
    S. T.

    Hi wyo3witt,
    I checked your account and saw that your subscription had been canceled, but that you hadn't been refunded yet. I processed a refund for you (transaction ID 0066152640); you see it in your account in 2-3 days.
    Best,
    Sara

  • FKPE1 - Create additional document FI-CA

    Hi all,
    I have a problem in FI-CA.
    When I post a document with FPE1 I want to create another document automatically.
    I have seen that it is possible with events (trx FQEVENTS).
    Probably the event i have to use are 10, 20 , 30. I have implemented 10 , 30. In event 30 i call fm FKK_CREATE_DOC_ADDITIONAL, but the system dump for an error message (Internal errore: lock missing for modification..).
    Anyone know how these event work?
    Thanks,
    enzo

    Were you able to make these events work. I am getting short dump  MESSAGE_TYPE_X.
    Please suggest .

  • Maybe you are looking for