I have a bunch of 'delete' links on a page that have a lot of power behind them. I want to add a confirmation window to confirm the delete before it happens.
I found this code that seems to provide the functionality i want:
But what i need to do is write the code into a function and be able to write out onclicks for each item in the recordset that will send their unique IDs to the function so it redirects to the correct URL that executes the delete.
Here's the ASP line inside a WHILE loop, reading from a SQL Recordset:
Response.write "<a href='sites.asp?co=" & intCompanyID & "&dv=" & intDivisionID & "&deleteSite=" & rsSite("S_ID").Value & "'>Delete</a>"
It's always going to go to sites.asp.
intCompanyID and intDivisionID are defined at the beginning of the page.
rsSite("S_ID") is the site ID being looped from the recordset.
or in the ASP loop it would look like: