This may not help in all situations, but the *nix file separator is
often used as the standard path separator: "/" instead of "\". All the
core Java classes function fine on Windows using "/" (they translate
it). If you used this instead of the backslash you will not need to
worry about escaping. Also, c:\MyFolder\ is not a valid URL despite
your bean property name. URL's must use forward slash. The w3c
standard for file URLs is:
file://c:/... not c:\
On 2/21/06, Adam <[EMAIL PROTECTED]> wrote:
> Dear All,
>
> I use a filename of an XML file someone is editing as a key value to
> look that file up (hashtable of dom objects)
>
> I then have to pass that back into the servelt so the backing bean knows
> which file to display.
>
> So imagine a file path such as C:\MyFolder\MyXML.xml
>
> I have within a commandlink:
>
> <f:param name="XMLFile" value="#{treeBacker.doc_URL}"/>
>
>
> Which then obviously comes out as C:MyFolderMyXML.xml
>
> using a std \\ does not work as it appears to strip one set of double \\
> on the way out & then one on the way back in
>
> i.e. instead of C:\\MyFolder\\MyXML.xml you have to have as an initial
> filepath of C:\\\\MyFolder\\\\MyXML.xml
>
>
> So how can I deal with this escaping problem?
>
> TIA
>
> Adam
>
>