[thelist] js alert to confirm deletion

Joshua Olson joshua at waetech.com
Tue Sep 24 14:53:00 CDT 2002


----- Original Message -----
From: "Dunstan Orchard" <dunstan at 1976design.com>
Sent: Tuesday, September 24, 2002 3:38 PM


> I have a link in a PHP page that reloads that page (with all the query
strings
> as well) and tacks on an extra query:

I don't know PHP, but I suspect this is a JS problem, not a PHP problem.

> <a href="$current_url&amp;DelPic=$imageid" title="Delete this
image">delete</a>

How about:
<a href="$current_url&amp;DelPic=$imageid"
title="Delete this image"
onclick="return confirm('Are you sure?');">delete</a>

That should do it.  The only thing I added was the onclick handler.

-joshua




More information about the thelist mailing list