How to include a URL in an XML fragment

Hello , my general question is how can I include a URL as a literal in an XML fragment , I tried this(please look at the bold part) but it would'nt work , I am getting a compile error because supposedly "<" is a special character in XML so how do I escape it or indeed how do I represent my URL? Your help is highly appreciated
<EndpointReference xmlns="http://schemas.xmlsoap.org/ws/2003/03/addressing [b]<https://webmail.bearingpoint.com/exchweb/bin/redir.asp?URL=http://schemas.xmlsoap.org/ws/2003/03/addressing> ">
<Address>https://secure-ausomxbxa.crmondemand.com/Services/Integration;j <https://webmail.bearingpoint.com/exchweb/bin/redir.asp?URL=https://secure-ausomxbxa.crmondemand.com/Services/Integration;j> sessionid=</Address>
<ServiceName xmlns:ns1="urn:crmondemand/ws/opportunity/10/2004">ns1:Opportunity</ServiceName>
</EndpointReference>

I don't know why you would want to surround your URL with < and > characters.
But the XML rule for escaping those characters in text nodes and attributes is that you escape < as < and > as >. The fact that URLs are involved in your case doesn't make any difference to that rule.
And normally if you're using XML software (e.g. Transformer, or Xerces's serializer) to write the document, it will take care of that detail for you. On the other hand if you're using ordinary java.io classes to write the document, you have to apply that rule yourself.

Similar Messages

  • How to Include the URL of a page in Notification Email ?

    Hi ALL,
    I need your help to implement the below requirement.
    I have implemented Email notification in our application.so when ever the user creates any form/modify the form ,mail will be triggered to them.Now the users want to include the link in the email.
    When they click the link in email ,it should be navigated to the newly created form page in Apex.
    How to include the link of the page in the Email process?
    Thanks,
    Ramya.

    Hi Tuceef,
    Thanks for the response.
    I have created another hidden item P8_URL1 IN page 8 and
    I have created an on submit process in page processing section.
    the pl/sql code is
    Begin
    htp.p('<script type = "text/javascript">');
    function setLocation(href)
               // set the location path specified in the textbox.
               htp.p('location.href = document.getElementById(href).value;');
              htp.p('P8_URL1:= location.href');
    htp.p('</script>');
    end;But the code fetching the plain URL only,it's navigating to the empty form page when i click on the URL.
    Please correct the code if am wrong anywhere!
    Thanks & Regards,
    Ramya.

  • How to include the URL in the name of the print job when printing from FF

    We log all print activity in our company and it would be helpful to be able to identify print jobs from Firefox, however as only a web page's <TITLE> content is used as the print job name, I was wondering if there was a way to either use the URL as the print job name, or even prefix the print job name as "Mozilla Firefox" to identify jobs from this application?

    Thank you for your reply but that's the print job content, i.e. page header / footer will have the URL typed into it. I'm after the name of the print job, i.e. as it appears in the print queue. For that I cannot find an option.
    I'm wondering whether a plug-in could do this, replace the normal print function with an identical one that uses the URL as the print job name.

  • Q: how to include a page in a region

    Hi all,
    i need some help
    how to include the URL of a page in a region, my requirement is that i have some links in the page and i need when i press a link a region under it will be rendered below it not in another page
    the links is ready and the pages is ready
    just i want a the region to contain a url based on the selected link.
    i know how to make a region rendered or not.
    and i have tried to use URiInclude but i couldn't figure out exactly how to do it
    i have also searched the forum and i couldn't find something about it.
    so please if any one knows the solution or can provide me with a link, i will be very thankful
    thanks

    user604057,
    Technically you can't add a page to another page. A page can have only one pagelayout region. So you will have to make a copy of those pages as regions without a pagelayout region and use.
    --Shiv                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Adding xml fragment to SOAP body (SAAJ)

    Hi all,
    we are using SOAP (or better SAAJ) in a modular design as packaging/enveloping format for arbitrary payloads which are generated by different modules.
    How is it possible to add a xml fragment (as InputStream or DOM Node) to a SOAP Body ?
    Nick
    [email protected]

    Hi Vicky,
    I guess, we have a little misunderstanding here. The core SOAP specification defines the structure of the envelope, the "SOAP with attachments" specification extends that by defining how to add binary attachments. This is accomplished by using MIME. Every attachment is another MIMEPart, but the SOAP Envelope always has to be present as first MIMEPart. Now I don't want to add any attachments, I only want to construct a SOAP Envelope that contains arbitrary xml docs (fragments) in the body.
    Look at the example below, the tags with namespace "S" belong to the SOAP specification and are built by our SOAP layer, the tags with namespace "m" belong to some other namespace and are generated by a totally different component.
    My question was how I could add (within SAAJ) the xml fragment starting with "m:PurchaseOrder" to the envelope without having to add element by element.
    <S:Envelope>
         <S:Header>
              ...optional header tags
         </S:Header>
         <S:Body>
                    <!---from here it is a different namespace, SOAP doesn't know about PurchaseOrders>
              <m:PurchaseOrder>
                   <m:position>
                        <m:article>0815</m:article>
                        <m:description>mainboard</m:description>
                        <m:price>50</m:price>
                   </m:position>
                   <m:position>
                        <m:article>0816</m:article>
                        <m:description>cpu</m:description>
                        <m:price>100</m:price>
                   </m:position>
              </PurchaseOrder>
                    <!---from here, it is SOAP again>
         </S:Body>
    </S:Envelope>

  • How to include custom application.xml in JDev9i project

    Can anybody explain to me how to include a custom application.xml file when deploying to an .ear file? I need to include application wide security roles, and I can't see where in Jev9i how to do this.
    After searching this forum, I see that jdev9i can't include the orion-application.xml, but I want to include just the standard J2EE application.xml. Is this possible?
    Thanks,
    matt

    The standard application.xml file unfortunately can't be customized in JDev 9.0.2. The reasons why this capability was left out of JDev 9.0.2 are same reasons why the other EAR-level XML files were excluded. The OTN thread
    Re: Regarding 11i and E-business suite
    has a summary of those reasons, which you've probably seen. We know this is an area in need of improvement and will be adding this functionality in the JDev 9.0.3 release. Until then, you'll have to go with a work-around like an Ant build file, batch file, Java application, or some other kind of script.
    Below is a sample Java application which can be used to insert <security-role> elements into an EAR file's application.xml. Modify the main() method to customize for your purposes, and put xmlparserv2.jar on the classpath (in a JDev project, add the "Oracle XML Parser v2" library):
    package mypackage4;
    import java.io.*;
    import java.util.*;
    import java.util.zip.*;
    import oracle.xml.parser.v2.*;
    import org.w3c.dom.*;
    import org.xml.sax.SAXException;
    public class PostProcessEAR
    public static void main( String[] args ) throws IOException
    final String earFile = "C:\\temp\\myapp.ear";
    final PostProcessEAR postProcess = new PostProcessEAR( earFile );
    postProcess.addSecurityRole( null, "first_role" );
    postProcess.addSecurityRole( "Description for the second role", "second_role" );
    postProcess.commit();
    System.out.println( "Done." );
    private final File _earFile;
    private final ArrayList _securityRoles = new ArrayList();
    public PostProcessEAR( String earFile )
    _earFile = new File( earFile );
    public void addSecurityRole( String description, String roleName )
    if ( roleName == null )
    throw new IllegalArgumentException();
    _securityRoles.add( description );
    _securityRoles.add( roleName );
    * Write out modified EAR file.
    public void commit() throws IOException
    if ( _securityRoles.size() == 0 )
    return;
    final ZipFile zipFile = new ZipFile( _earFile );
    final Enumeration entries = zipFile.entries();
    final File outFile = new File( _earFile.getAbsolutePath() + ".out" );
    final ZipOutputStream out = new ZipOutputStream( new BufferedOutputStream( new FileOutputStream( outFile ) ) );
    while ( entries.hasMoreElements() )
    final ZipEntry entry = (ZipEntry) entries.nextElement();
    final InputStream in = zipFile.getInputStream( entry );
    if ( "META-INF/application.xml".equals( entry.getName() ) )
    final XMLDocument modifiedApplicationXml = insertSecurityRoles( in );
    final ByteArrayOutputStream byteOutput = new ByteArrayOutputStream();
    modifiedApplicationXml.print( byteOutput );
    final int numBytes = byteOutput.size();
    entry.setSize( numBytes );
    if ( entry.getMethod() == ZipEntry.STORED )
    entry.setCompressedSize( numBytes );
    final CRC32 crc32 = new CRC32();
    crc32.update( byteOutput.toByteArray() );
    entry.setCrc( crc32.getValue() );
    out.putNextEntry( entry );
    byteOutput.writeTo( out );
    else
    // Copy all other zip entries as they are.
    out.putNextEntry( entry );
    copy( in, out );
    in.close();
    out.close();
    private XMLDocument insertSecurityRoles( InputStream in ) throws IOException
    final DOMParser domParser = new DOMParser();
    domParser.setAttribute( DOMParser.STANDALONE, Boolean.TRUE );
    try
    domParser.parse( in );
    final XMLDocument doc = domParser.getDocument();
    final Element docElem = doc.getDocumentElement();
    final Iterator iter = _securityRoles.iterator();
    while ( iter.hasNext() )
    final String desc = (String) iter.next(); // might be null
    final String roleName = iter.next().toString(); // must not be null
    final Element securityRoleElem = doc.createElement( "security-role" );
    if ( desc != null )
    securityRoleElem.appendChild( createPcdata( doc, "description", desc ) );
    securityRoleElem.appendChild( createPcdata( doc, "role-name", roleName ) );
    docElem.appendChild( securityRoleElem );
    return doc;
    catch ( SAXException e )
    e.printStackTrace();
    return null;
    private Element createPcdata( XMLDocument doc, String elemName, String pcdata )
    final Element elem = doc.createElement( elemName );
    elem.appendChild( doc.createTextNode( pcdata ) );
    return elem;
    private final byte[] buffer = new byte[4096];
    private void copy( InputStream in, OutputStream out ) throws IOException
    while ( true )
    final int bytesRead = in.read( buffer );
    if ( bytesRead < 0 )
    break;
    out.write( buffer, 0, bytesRead );

  • 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.

  • How do I include custom URLs in a Sharepoint Search?

    I have links pointing to files on our file server.
    I would like to have these links show up in a Sharepoint search.
    Any idea how to accomplish this?

    Hi Packard,
    To include the URLs pointing to files on the file server in SharePoint search, I recommend to store the URLs in a list and then you can search the keywords in the list to get the corresponding items.
    However, if you want to display the URLs in search results, you need to modify the search result display template to show the field value which is used to store the URLs.
    http://blogs.technet.com/b/tothesharepoint/archive/2013/09/11/how-to-display-values-from-custom-managed-properties-in-search-results-option-1.aspx
    http://blogs.technet.com/b/tothesharepoint/archive/2013/09/12/how-to-display-values-from-custom-managed-properties-in-search-results-option-2.aspx
    And you can also use Content Search web part to show the URLs in search results.
    Please edit the web part and then edit the Property Mappings to add the managed property for the field which is used to store the URLs(you need to create the managed property for the crawled property of the field in Search service application first and remember
    to do a full crawl).
    Best regards.
    Thanks
    Victoria Xia
    TechNet Community Support

  • How to include the first row of detail in every xquery transformed xml?

    I am dealing with a XML file,where i need to publish to different BS.
    First node will be a common node node which contains vital info,second node goes to one BS and third goes to another BS.
    *<header></header>*
    *<details></details> (they are unbounded, but the first detail tag which comes in the input file is a mandatory tag in such a way that it needs to be included in every transformed message)*
    *<trailer></trailer>*
    We need to apply x query transformation on it in such a way:
    *</header></header>*
    *<1st detail></1st detail>*
    *<detail></detail> (2nd row of detail in input file)* -------------------------> Goes to BS1
    *<trailer></trailer>..*
    *<header></header>*
    *<1st detail></1st detail>*
    *<detail></detail> (3rd row of detail in input file)* ----------------------------->Goes to BS2
    *<trailer></trailer>*..
    And so on.
    Now, the problem is how to include the first row( *1st detail* ) of detail in every xquery transformed xml?

    are you looping of this input with a for each?
    /yourdata/details[1] should return always the first detail element.
    or before the for each do an assing of this first detail element to "generic_details_var"
    and use this var in every looping iteration (in an assign or as input for xquery)

  • How to include the file name as an XML field

    Hi,
    I'm using a file adapter for process a flat file and convert it into an XML. Does anybody knows how to include the file name into an XML field.
    Ex.
    I process the file named <b>XXIMN21022007.txt</b> and I need an XML like:
    <MT_FILE>
    <field1></field1>
    <field2></field2>
    <field3></field3>
    <filename><b>XXIMN21022007.txt</b></filename>
    </MT_FILE>
    Regards
    Gonzalo

    Just go for dynamic configuration.
    Check the sender file adapter to write the filename in the header (as explained in Michal's blog) and then read that header in some mapping.
    U can use that even in simple message mappings.
    http://help.sap.com/saphelp_nw2004s/helpdata/en/43/03612cdecc6e76e10000000a422035/frameset.htm
    Your code for the filename tag would be something like:
    <i>DynamicConfiguration conf = (DynamicConfiguration) container
        .getTransformationParameters()
        .get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
    DynamicConfigurationKey key = DynamicConfigurationKey.create(
        “http://sap.com/xi/XI/System/File”,
        “FileName”);
    return conf.get(key);</i>
    Regards,
    Henrique.

  • How to include .js file into validater-rules.xml

    iam doing project using struts.
    i have .js file for client side validation.how to include .js file into struts validate-rules.xml so that i can use those validation in my project.
    without writing any class.
    is there any way

    copy + paste from my book...............
    Enabling Client-Side Validations
    In addition to providing a framework for simplifying server-side form data validations, Validator provides an easy-to-use mechanism for performing client-side validations. Each validation routine defined in the validator-rules.xml file optionally specifies JavaScript code that can be run in the browser (client side) to perform the same validations that take place on the server side. When run on the client side, the validations will not allow the form to be submitted until they have all passed.
    To enable client-side validation, you have to place the HTML Tag Library's javascript tag in each JSP for which you want validation performed, as shown here:
    <html:javascript formName="logonForm"/>
    The javascript tag requires that you use the formName attribute to specify the name of a <form> definition from the validation.xml file, as shown here, for which you want validations performed:
    <form name="logonForm">
    <field property="username" depends="required">
    <arg0 key="prompt.username"/>
    </field>
    <field property="password" depends="required">
    <arg0 key="prompt.password"/>
    </field>
    </form>
    All the validations that you have specified for the <form> definition to run on the server side will be run on the client side.

  • 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.

  • How to include variable inside XML Fragment in assign ?

    HI..how are you today.
    i need to assign an XML Fragment...like this into a variable:
    <tns:pCmds>put @Encoded_Filename@</tns:pCmds>
    <tns:pCmds>bye</tns:pCmds>
    that Encoded_Filename is a variable..but of course..it is taking the whole put ...as a string...how can i tell bpel that the @@ is a variable?
    i remember having some escape char to do so, but can figure out now..
    Thanks in advance
    P.

    ok, i got what you were saying about CDATA, but i think my problem is the opposite..i WANT my string to be parsed..
    when i assign <tag> put @filename@ </tag> i need that variable to be replaced..and right now, it is taken all as a simple string...

  • How to include atribute xsi:type in the xml generated through java

    Hi,
    i am generating an xml using java and castor.
    I want to include this attribute in my xml:
    xsi:type="abc"
    for example:
    My snippet is:
    Underwriting_detail[] underwritingDetail = new Underwriting_detail[1];
    underwritingDetail[0] = new Underwriting_detail();
    underwritingDetail[0].setContent(fulfillmentPreResponseTO.getUnderwritingDetailsMainAnswer1());
    underwritingDetail[0].setQuestion_code(fulfillmentPreResponseTO.getUnderwritingDetailsMainQuestionCode1());
    underwritingDetail[0].setAnswer_format(AnswerFormatType.YESNO);
    underwritingDetail[0].setSequence_number(fulfillmentPreResponseTO.getUnderwritingDetailsSequenceNumber());
    Result is:
    <underwriting_detail answer_format="YesNo" sequence_number="1" question_code="JVL1Q1">NO</underwriting_detail>
    The requirement is:
    <underwriting_detail xsi:type="NonStdUWQuestion" answer_format="YesNo" sequence_number="1" question_code="JVL1Q1">No</underwriting_detail>
    There is no method defined in the underwriting_detail class to add this attribute. Is there any way to add this xsi:type="NonStdUWQuestion" in this tag?

    yes, is a question of JSF
    Component dataTable

  • How to include Material Cost in the SD report

    Hi,
    I am working on Cube 0SD_C03 for the Sales and Distribution Report "Sales Contribution - Product Wise u2013 KPI" where I have to show the following information which are given below.
    1. Total Sales Qty.
    2. Total Sales Value
    3. Total Material Cost
    For third one I do not know how to include this in this SD report.
    so please tell me about this if anybody has idea about this?

    Hi Francisco,
    Note:
    your xml should only have
    <URL>http://dbxserver.dbxprts.com:7778/pls/apex/f?p=134:1:::NO::P1_ID_CONSTANCIA:1183</URL>
    Show me your sample XML , i can help you.
    What is your expected output ? PDF or HTML ?
    here it is.
    option1:
    If the XML data includes an element that contains a hyperlink , then you can use that element to create dynamic hyperlinks at runtime.
    a. insert hyperlink from word menu
    b. In the Type the file or Web page name field of the Insert Hyperlink dialog box, enter the following syntax:
    c. {ELEMENT_NAME_WHICH_HAS_URL_LINK}
    where ELEMENT_NAME_WHICH_HAS_URL_LINK is the xml data element name
    option2:
    create a form field, you can add it
    <fo:basic-link external-destination="http://www.google..com">
    <fo:inline text-decoration="underline">google Link</fo:inline>
    </fo:basic-link>
    or
    <fo:basic-link external-destination="{ELEMENT_NAME}">
    <fo:inline text-decoration="underline">google Link</fo:inline>
    </fo:basic-link>
    or
    <fo:basic-link>
    <xsl:attribute name="external-destination"><xsl:value-of select="ELEMENT_URL"/>
    </xsl:attribute>
           <xsl:value-of select="LINK_NAME"/>
    </fo:basic-link>

Maybe you are looking for

  • How to use 10.9.8.y/24 network?

    I just bought an Airport Extreme Base Station, new model and upgraded to the latest software and firmware. I've had a home network for many years, through many routers, and have always used the 10.9.8.x/24 network. The new Airport is set up and worki

  • Grey wifi and bluetooth

    I have an old iPod  that my friend gave me and I thing the wifi and bluetooth antenna is broken because in the setting they are both greyed out and I can't click them. If I take it in to an apple store can they fix it or replace it or what?

  • Devices and playback

    After setting my interface (M-audio Firewire solo) as the device in the audio preferences I found that I can only hear anything through headphones connected to the interface or by setting the device back to 'built in microphone'. Is there a way of se

  • Resource utilization gantt chart popup

    Hi, In resource utilization gantt chart component, I need to display the task and its details in a popup component or hovering the time bucket bars. How to achieve this using Jdev 11.1.1.3 version? Thanks in advance.

  • Why won't NY Times photos display?

    Screen is blank. Rt click to view photo just enlarged blank screen.