I have a connection string in my web config:
connectionString="Server=dbsrv;User ID=myDbUser;Password=somepass"word"
Since the web.config is XML, you need to escape the five special characters:
& -> & ampersand, U+0026
< -> < left angle bracket, less-than sign, U+003C
> -> > right angle bracket, greater-than sign, U+003E
" -> " quotation mark, U+0022
' -> ' apostrophe, U+0027
+ is not a problem, I suppose.
Duc Filan adds:
You should also wrap your password with single quote ':
connectionString="Server=dbsrv;User ID=myDbUser;Password='somepass"word'"