p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

asp_databases thread: Apostrophe bug


Message #1 by "Paul Cracknell" <paul.cracknell@b...> on Sun, 2 Dec 2001 18:36:20
I am surely not the first person to notice that asp forms do not work if 

the user places " or ' in the text submission. 



I know enough to know why the pages fail but I don't know enough to know 

how to resolve the problem. 



I could request users not to use speech-marks or quotation marks but It 

would not look good on the form and as I don't see this request on anyone 

else's forms I am quessing that there must be a solution.



Any suggestions would be gratefully received.



Paul.C
Message #2 by "Kim Iwan Hansen" <kimiwan@k...> on Sun, 2 Dec 2001 21:35:18 +0100
hi paul,



take a look here:

http://www.asplists.com/learn/FAQdbSinglequote.asp



-Kim







-----Original Message-----

From: Paul Cracknell [mailto:paul.cracknell@b...]

Sent: 2. december 2001 18:36

To: ASP Databases

Subject: [asp_databases] Apostrophe bug





I am surely not the first person to notice that asp forms do not work if

the user places " or ' in the text submission.



I know enough to know why the pages fail but I don't know enough to know

how to resolve the problem.



I could request users not to use speech-marks or quotation marks but It

would not look good on the form and as I don't see this request on anyone

else's forms I am quessing that there must be a solution.



Any suggestions would be gratefully received.



Paul.C






$subst('Email.Unsub')



Read the future with ebooks at B&N

http://service.bfast.com/bfast/click?bfmid=2181&sourceid=38934667&categoryid

=rn_ebooks



Message #3 by dont worry <aspmailbox@y...> on Sun, 2 Dec 2001 13:55:18 -0800 (PST)
you should use a built-in function called replace that

can find characters in a string and replace them with

alternate characters

--- Kim Iwan Hansen <kimiwan@k...> wrote:

> hi paul,

> 

> take a look here:

> http://www.asplists.com/learn/FAQdbSinglequote.asp

> 

> -Kim

> 

> 

> 

> -----Original Message-----

> From: Paul Cracknell

> [mailto:paul.cracknell@b...]

> Sent: 2. december 2001 18:36

> To: ASP Databases

> Subject: [asp_databases] Apostrophe bug

> 

> 

> I am surely not the first person to notice that asp

> forms do not work if

> the user places " or ' in the text submission.

> 

> I know enough to know why the pages fail but I don't

> know enough to know

> how to resolve the problem.

> 

> I could request users not to use speech-marks or

> quotation marks but It

> would not look good on the form and as I don't see

> this request on anyone

> else's forms I am quessing that there must be a

> solution.

> 

> Any suggestions would be gratefully received.

> 

> Paul.C

> 



> kimiwan@k...


> $subst('Email.Unsub')

> 

> Read the future with ebooks at B&N

>

http://service.bfast.com/bfast/click?bfmid=2181&sourceid=38934667&categoryid

> =rn_ebooks

> 

> 

>  



> aspmailbox@y...


> $subst('Email.Unsub')

> 

> Read the future with ebooks at B&N

>

http://service.bfast.com/bfast/click?bfmid=2181&sourceid=38934667&categoryid=rn_ebooks





__________________________________________________

Do You Yahoo!?

Buy the perfect holiday gifts at Yahoo! Shopping.

http://shopping.yahoo.com

Message #4 by "Prakash" <warana2000@y...> on Fri, 7 Dec 2001 12:40:11
Hi,

To solve this problem u can use following statement while inserting the 

record into the database

           replace(var,"'","''")



it will solve u r problem.

it will insert the reord properly

from

Prakash





> I am surely not the first person to notice that asp forms do not work if 

> the user places " or ' in the text submission. 

> 

> I know enough to know why the pages fail but I don't know enough to know 

> how to resolve the problem. 

> 

> I could request users not to use speech-marks or quotation marks but It 

> would not look good on the form and as I don't see this request on 

anyone 

> else's forms I am quessing that there must be a solution.

> 

> Any suggestions would be gratefully received.

> 

> Paul.C

  Return to Index