Print Page | Close Window

Replace "

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=15001
Printed Date: 30 March 2026 at 5:05am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Replace "
Posted By: ub3rl337ch3ch
Subject: Replace "
Date Posted: 09 May 2005 at 10:22pm

How do i get replace() to remove all the "s in a string?

replace(string,","") single quote?
replace(string,""","") triple quote?
replace(string,"'"'","") quote, apost, quote, apost, quote?



Replies:
Posted By: WebWiz-Bruce
Date Posted: 10 May 2005 at 5:07am
replace(string,""") single quote
replace(string,"""") double quote
replace(string,""""") triple quote


-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting


Posted By: ub3rl337ch3ch
Date Posted: 10 May 2005 at 7:00pm
so the default replacement for replace() is nothing?


Posted By: ub3rl337ch3ch
Date Posted: 10 May 2005 at 8:09pm
I try
 
theString = replace(theString,""")
and it complains of "Unterminated string constant"


Posted By: Mart
Date Posted: 11 May 2005 at 2:45am
you need to use

theString = replace(theString,"""")

if you want to use a literal " in a string in ASP you have to double them up (i.e. "")



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net