I've got an issue with an ASP site that uses an access database. It's probably a simple fix but i'm not familiar with ASP/access.
The issue has only emerged recently however reverting the content by restoring a backup of the DB doesn't seem to have fixed it. Other pages on the site are quite similar and work fine.
When the user saves the page they get:
save_section.asp, line 22
The line line mentioned from save_section.asp relates to sanitising the inputs for the access DB (see below)
There isn't really anything else to the file, the other parts are just the query and the response redirect once the query completes.
Let me know if I've missed any information which would help.
Dim strSQLpage, rsPage
strSQLpage = "UPDATE tablename SET pagename = '" & MakeTextDBSafe(Request.Form("textarea")) & "' WHERE idpage = " & request.form("pageid")
'Set rsPage = Server.CreateObject("ADODB.recordset")
Set rsPage = dbCon.Execute(strSQLpage)
response.redirect "cms.asp?pageid=" & request.form("pageid") & "&saved=1"
'replace apostrophies with double apostrophies
strSafeText = Replace(strInputText, "'", "''") '<--LINE 22
MakeTextDBSafe = Trim(strSafeText)