Login  Register

Re: url-generator

Posted by Joseph Lawrence on Mar 05, 2007; 4:24am
URL: https://discuss.orbeon.com/url-generator-tp32999p33000.html

Hi Ryan,
    I think the URL generator, unless otherwise specified, uses the oxf as context. Hence I think using something like below might work. But if you can't use absolute URL, I not sure of how to accomplish this.

    <p:processor name="oxf:xhtml-rewrite">
        <p:input name="rewrite-in"><xhtml:a href="/services/db/get"/></p:input>
        <p:output name="rewrite-out" id="rewritten-url">
    </p:processor>

    <p:processor name="oxf:xslt">
        <p:input name="data" href="#rewritten-url"/>
        <p:input name="config">
            <config xsl:version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
                <url>https://localhost:8888<xsl:value-of select="//@href"/></url>
                <content-type>application/xml</content-type>
            </config>
        </p:input>
        <p:output name="data" id="url-generator-config"/>
    </p:processor>

    <p:processor name="oxf:url-generator">
        <p:input name="config" href="#url-generator-config"/>
        <p:output name="data" ref="data"/>
    </p:processor>

Thanks
Joseph Lawrence
Stabilix Solutions

Ryan Puddephatt <[hidden email]> wrote:
Hi,
I'm trying to use the url-generator to return a relative url within
the same context such as /services/db/get

But it keeps returning Cannot load "/contracts/services/db/get" with
webapp loader

There isn't anything in the documentation about context relative urls,
is this possible? I can't use an absolute url because of SSL and
authentication on the server

Ryan

Ryan Puddephatt
Software Engineer

Teleflex Group - IT UK
1 Michaelson Square
Livingston
West Lothian
Scotland
EH54 7DP

e> [hidden email]
t> +44(0)1506 407 110
f> +44(0)1506 407 108
w> www.teleflex.com



--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws


We won't tell. Get more on shows you hate to love
(and love to hate): Yahoo! TV's Guilty Pleasures list.

--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws