Hello
I try to source out a fragment of my view in a separate file and including it via xinclude. This fragment uses a <xforms:output mediatype=image/* value= img/empty.gif/> that do work inline but do not when sourcing out and including it. Question: Is the context of the relative address img/empty.gif changed when using xinclude and to what? -Peter -- 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 |
Administrator
|
Peter,
Good point! As per the spec, XInclude does add an xml:base attribute on included elements which is set to the location of the included file. Since we perform xml:base handling for URL resolution, yes, your image URL will be relative to the location of the included file, which is not what you want. Can you not use XInclude in the case? -Erik [hidden email] wrote: > Hello > I try to source out a fragment of my view in a separate file and including it via xinclude. > > This fragment uses a > <xforms:output mediatype=”image/*” value= “’img/empty.gif’”/> > > that do work inline but do not when sourcing out and including it. > > Question: Is the context of the relative address img/empty.gif changed when using xinclude and to what? > > > -Peter -- 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 |
In reply to this post by Peter.Heintz
Erik,
If I understand you right, I just have e.g. to put my empty.gif in the same folder where my included file is, and refer to it by value='empty.gif'. But this does not work. What do you mean by your suggestion to use XInclude? I think I use XInclude. Mit freundlichen Grüßen / Best regards, Peter Heintz -- -----Ursprüngliche Nachricht----- Von: Erik Bruchez [mailto:[hidden email]] Im Auftrag von Erik Bruchez Gesendet: Mittwoch, 1. Februar 2006 09:55 An: [hidden email] Betreff: Re: [ops-users] xi:include in view Peter, Good point! As per the spec, XInclude does add an xml:base attribute on included elements which is set to the location of the included file. Since we perform xml:base handling for URL resolution, yes, your image URL will be relative to the location of the included file, which is not what you want. Can you not use XInclude in the case? -Erik [hidden email] wrote: > Hello > I try to source out a fragment of my view in a separate file and including it via xinclude. > > This fragment uses a > <xforms:output mediatype="image/*" value= "'img/empty.gif'"/> > > that do work inline but do not when sourcing out and including it. > > Question: Is the context of the relative address img/empty.gif changed when using xinclude and to what? > > > -Peter -- 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 |
Peter,
You could try using XSLT in the instance. <xsl:copy-of select="doc('oxf:/path/to/my.xml')/*"/> Ryan Puddephatt Web Developer TFX Group 1 Michaelson Square Livingston West Lothian Scotand EH54 7DP * [hidden email] ( 01506 407 110 7 01506 407 108 >-----Original Message----- >From: [hidden email] [mailto:[hidden email]] >Sent: 01 February 2006 11:08 >To: [hidden email] >Subject: AW: [ops-users] xi:include in view > >Erik, >If I understand you right, I just have e.g. to put my empty.gif in the same >folder where my included file is, and refer to it by value='empty.gif'. >But this does not work. > >What do you mean by your suggestion to use XInclude? > >I think I use XInclude. > > >Mit freundlichen Grüßen / Best regards, >Peter Heintz > >-- > > >-----Ursprüngliche Nachricht----- >Von: Erik Bruchez [mailto:[hidden email]] Im Auftrag von Erik Bruchez >Gesendet: Mittwoch, 1. Februar 2006 09:55 >An: [hidden email] >Betreff: Re: [ops-users] xi:include in view > >Peter, > >Good point! > >As per the spec, XInclude does add an xml:base attribute on included >elements which is set to the location of the included file. Since we >perform xml:base handling for URL resolution, yes, your image URL will >be relative to the location of the included file, which is not what you >want. Can you not use XInclude in the case? > >-Erik > >[hidden email] wrote: >> Hello >> I try to source out a fragment of my view in a separate file and >including it via xinclude. >> >> This fragment uses a >> <xforms:output mediatype="image/*" value= "'img/empty.gif'"/> >> >> that do work inline but do not when sourcing out and including it. >> >> Question: Is the context of the relative address img/empty.gif changed >when using xinclude and to what? >> >> >> -Peter > > -- 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 |
In reply to this post by Peter.Heintz
Ryan,
Yes, thank you this works form me. I just wanted to understand the behaviour of XInlude. Mit freundlichen Grüßen / Best regards, Peter Heintz -----Ursprüngliche Nachricht----- Von: Ryan Puddephatt [mailto:[hidden email]] Gesendet: Mittwoch, 1. Februar 2006 12:15 An: [hidden email] Betreff: RE: [ops-users] xi:include in view Peter, You could try using XSLT in the instance. <xsl:copy-of select="doc('oxf:/path/to/my.xml')/*"/> Ryan Puddephatt Web Developer TFX Group 1 Michaelson Square Livingston West Lothian Scotand EH54 7DP * [hidden email] ( 01506 407 110 7 01506 407 108 >-----Original Message----- >From: [hidden email] [mailto:[hidden email]] >Sent: 01 February 2006 11:08 >To: [hidden email] >Subject: AW: [ops-users] xi:include in view > >Erik, >If I understand you right, I just have e.g. to put my empty.gif in the same >folder where my included file is, and refer to it by value='empty.gif'. >But this does not work. > >What do you mean by your suggestion to use XInclude? > >I think I use XInclude. > > >Mit freundlichen Grüßen / Best regards, >Peter Heintz > >-- > > >-----Ursprüngliche Nachricht----- >Von: Erik Bruchez [mailto:[hidden email]] Im Auftrag von Erik Bruchez >Gesendet: Mittwoch, 1. Februar 2006 09:55 >An: [hidden email] >Betreff: Re: [ops-users] xi:include in view > >Peter, > >Good point! > >As per the spec, XInclude does add an xml:base attribute on included >elements which is set to the location of the included file. Since we >perform xml:base handling for URL resolution, yes, your image URL will >be relative to the location of the included file, which is not what you >want. Can you not use XInclude in the case? > >-Erik > >[hidden email] wrote: >> Hello >> I try to source out a fragment of my view in a separate file and >including it via xinclude. >> >> This fragment uses a >> <xforms:output mediatype="image/*" value= "'img/empty.gif'"/> >> >> that do work inline but do not when sourcing out and including it. >> >> Question: Is the context of the relative address img/empty.gif changed >when using xinclude and to what? >> >> >> -Peter > > -- 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 |
Peter,
From what Eric was saying I agree with the way you were using the XInclude, although I would still have thought the image path would have been relevant to the page rather than XML. Although not having used XInclude within my instance for relative paths I wouldn't know! If you do find out let us know, would be handy Ryan Ryan Puddephatt Web Developer TFX Group 1 Michaelson Square Livingston West Lothian Scotand EH54 7DP * [hidden email] ( 01506 407 110 7 01506 407 108 >-----Original Message----- >From: [hidden email] [mailto:[hidden email]] >Sent: 01 February 2006 11:37 >To: [hidden email] >Subject: AW: [ops-users] xi:include in view > >Ryan, >Yes, thank you this works form me. > >I just wanted to understand the behaviour of XInlude. > > >Mit freundlichen Grüßen / Best regards, > >Peter Heintz > > >-----Ursprüngliche Nachricht----- >Von: Ryan Puddephatt [mailto:[hidden email]] >Gesendet: Mittwoch, 1. Februar 2006 12:15 >An: [hidden email] >Betreff: RE: [ops-users] xi:include in view > >Peter, > You could try using XSLT in the instance. > ><xsl:copy-of select="doc('oxf:/path/to/my.xml')/*"/> > >Ryan Puddephatt >Web Developer >TFX Group >1 Michaelson Square >Livingston >West Lothian >Scotand >EH54 7DP > >* [hidden email] >( 01506 407 110 >7 01506 407 108 > > >>-----Original Message----- >>From: [hidden email] [mailto:[hidden email]] >>Sent: 01 February 2006 11:08 >>To: [hidden email] >>Subject: AW: [ops-users] xi:include in view >> >>Erik, >>If I understand you right, I just have e.g. to put my empty.gif in the >same >>folder where my included file is, and refer to it by value='empty.gif'. >>But this does not work. >> >>What do you mean by your suggestion to use XInclude? >> >>I think I use XInclude. >> >> >>Mit freundlichen Grüßen / Best regards, >>Peter Heintz >> >>-- >> >> >>-----Ursprüngliche Nachricht----- >>Von: Erik Bruchez [mailto:[hidden email]] Im Auftrag von Erik Bruchez >>Gesendet: Mittwoch, 1. Februar 2006 09:55 >>An: [hidden email] >>Betreff: Re: [ops-users] xi:include in view >> >>Peter, >> >>Good point! >> >>As per the spec, XInclude does add an xml:base attribute on included >>elements which is set to the location of the included file. Since we >>perform xml:base handling for URL resolution, yes, your image URL will >>be relative to the location of the included file, which is not what you >>want. Can you not use XInclude in the case? >> >>-Erik >> >>[hidden email] wrote: >>> Hello >>> I try to source out a fragment of my view in a separate file and >>including it via xinclude. >>> >>> This fragment uses a >>> <xforms:output mediatype="image/*" value= "'img/empty.gif'"/> >>> >>> that do work inline but do not when sourcing out and including it. >>> >>> Question: Is the context of the relative address img/empty.gif changed >>when using xinclude and to what? >>> >>> >>> -Peter >> >> > > > -- 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 |
Administrator
|
In reply to this post by Peter.Heintz
[hidden email] wrote:
> Erik, > If I understand you right, I just have e.g. to put my empty.gif in the same folder where my included file is, and refer to it by value='empty.gif'. > But this does not work. This will not work, because the resolved URL will be of the form "oxf:/", which your browser will not understand. > What do you mean by your suggestion to use XInclude? Unfortunately, because of xml:base resolution, I can't see a perfect solution at this point. As mentioned, you can perform your inclusion with XSTL instead of XInclude. In the future, we may want to provide an extension to XInclude that allows you to prevent xml:base generation. -Erik -- 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 |
In reply to this post by Peter.Heintz
That's fine.
Peter Heintz -----Ursprüngliche Nachricht----- Von: Erik Bruchez [mailto:[hidden email]] Im Auftrag von Erik Bruchez Gesendet: Mittwoch, 1. Februar 2006 14:13 An: [hidden email] Betreff: Re: AW: [ops-users] xi:include in view [hidden email] wrote: > Erik, > If I understand you right, I just have e.g. to put my empty.gif in the same folder where my included file is, and refer to it by value='empty.gif'. > But this does not work. This will not work, because the resolved URL will be of the form "oxf:/", which your browser will not understand. > What do you mean by your suggestion to use XInclude? Unfortunately, because of xml:base resolution, I can't see a perfect solution at this point. As mentioned, you can perform your inclusion with XSTL instead of XInclude. In the future, we may want to provide an extension to XInclude that allows you to prevent xml:base generation. -Erik -- 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 |
Free forum by Nabble | Edit this page |