[MarkLogic Dev General] Re: & (Norman Walsh)
Paul M
pjmaip at yahoo.com
Fri Jan 9 06:28:52 PST 2009
------------------------------
Message: 4
Date: Wed, 07 Jan 2009 13:06:44 -0500
From: Norman Walsh <ndw at nwalsh.com>
Subject: Re: [MarkLogic Dev General] &
To: General Mark Logic Developer Discussion
<general at developer.marklogic.com>
Message-ID: <m2ocyj3s97.fsf at nwalsh.com>
Content-Type: text/plain
Shannon <Shiflett at virginia.edu> writes:
> I understand that in XML and XQuery an ampersand needs to be written
> as &, but I need a constructed node to be output with a literal
> "&" string, but it's being translated into & --
The following tag
> in an XQY prolog:
>
> <object>
> <embed flashvars="{concat("zoomifyImagePath=img/",
$filename,
> "&zoomifySplashScreen=0")}"
src="ZoomifyViewer.swf" menu="false"
> pluginspage="http://www.adobe.com/go/getflashplayer"
> type="application/ x-shockwave-flash" width="800"
height="500"
> name="ZoomifyViewer"></ embed>
> </object>
>
> I have tried encoding and escaping. Please, is there a workaround?
Are you sure that putting the escaped & in there is a problem?
If you send
<embed
flashvars="zoomifyImagePath=img/someFn&zoomifySplashScreen=0"
to a browser, it should interpret that attribute value as
"zoomifyImagePath=img/someFn&zoomifySplashScreen=0"
which is presumably what the plugin wants. If you could persuade the
generated HTML to include
<embed
flashvars="zoomifyImagePath=img/someFn&zoomifySplashScreen=0"
you'd be relying on quirky parsing at best.
OTOH, maybe what I've just said applyes to XHTML but not HTML. Still,
it might be worth testing...
Be seeing you,
norm
--
Norman Walsh
Principal Technologist
Mark Logic Corporation
------------------------------
Message: 5
Date: Wed, 7 Jan 2009 13:56:09 -0500
From: Shannon <Shiflett at virginia.edu>
Subject: Re: [MarkLogic Dev General] &
To: General Mark Logic Developer Discussion
<general at developer.marklogic.com>
Message-ID: <19EF4394-B858-4AD2-AAD8-14DF5B619C6E at virginia.edu>
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
Norm, you called it. I had convinced myself it was the problem, but
as a test, I saved the ouput, changed & to & and reloaded the
static page and ended up with the same result, so, something's up with
the plugin. Thanks for zeroing in on this one.
On Jan 7, 2009, at 1:06 PM, Norman Walsh wrote:
> Shannon <Shiflett at virginia.edu> writes:
>> I understand that in XML and XQuery an ampersand needs to be written
>> as &, but I need a constructed node to be output with a
literal
>> "&" string, but it's being translated into &
-- The following tag
>> in an XQY prolog:
>>
>> <object>
>> <embed flashvars="{concat("zoomifyImagePath=img/",
$filename,
>> "&zoomifySplashScreen=0")}"
src="ZoomifyViewer.swf" menu="false"
>> pluginspage="http://www.adobe.com/go/getflashplayer"
>> type="application/ x-shockwave-flash" width="800"
height="500"
>> name="ZoomifyViewer"></ embed>
>> </object>
>>
>> I have tried encoding and escaping. Please, is there a workaround?
>
> Are you sure that putting the escaped & in there is a problem?
>
> If you send
>
> <embed flashvars="zoomifyImagePath=img/
> someFn&zoomifySplashScreen=0"
>
> to a browser, it should interpret that attribute value as
>
> "zoomifyImagePath=img/someFn&zoomifySplashScreen=0"
>
> which is presumably what the plugin wants. If you could persuade the
> generated HTML to include
>
> <embed
flashvars="zoomifyImagePath=img/someFn&zoomifySplashScreen=0"
>
> you'd be relying on quirky parsing at best.
>
> OTOH, maybe what I've just said applyes to XHTML but not HTML. Still,
> it might be worth testing...
>
> Be seeing you,
> norm
>
> --
> Norman Walsh
> Principal Technologist
> Mark Logic Corporation
> _______________________________________________
> General mailing list
> General at developer.marklogic.com
> http://xqzone.com/mailman/listinfo/general
In xhtml, according to specs, < > and & (maybe two more) must be escaped in attribute values.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://xqzone.marklogic.com/pipermail/general/attachments/20090109/224314f6/attachment.html
More information about the General
mailing list