|
-
April 6th, 2011, 02:52 AM
#1
ASP.NET escape quotes?
Hi,
In ASP.NET, when you have quotes within a variable, how do you escape them?
For instance, it might look like this:
myvar = "<input type="text" name="mytext">"
I know in PHP this is so easy because you can just use a \".
Does anybody have any idea how this would be done in ASP.NET?
Thanks for your help
-
April 7th, 2011, 03:05 AM
#2
Re: ASP.NET escape quotes?
It's different whether you use C# or VB.NET.
If using C# it is \ if I remember right (can also use @before a string)
If using VB.NET an additional " will escape the following ".
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|