On 12/18/2003 02:54 AM Justin Ruthenbeck wrote:
At 05:34 PM 12/17/2003, you wrote:

Hi,
I'm using mysql via JDBC and I need to encode a password with non-alphabet characters in it like % in my server.xml.


Do I use a URL encoding for this or an XML encoding?


I don't know for sure as I haven't used mysql specifically, but if the password will be read by an xml parser, then you'll want to xml encode it. If the password is part of a URI that is specified in an XML, then you'll want to URL-encode the character(s) and XML encode any problematic characters from that output.

Also while I'm on the subject, do I have to encode or escape a double-quote in an xml attribute:

<mynode attr1="blahblah\"blah\"blah"/>


&quot; in this case. This can depend on your parser (or at least it has in older parsers).

Thanks
Adam


justin

Thanks v. much


Adam
--
struts 1.1 + tomcat 5.0.16 + java 1.4.2
Linux 2.4.20 Debian


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to