Delete Confirm Button

Delete Confirm Button

technoicontechnoicon Posts: 12Questions: 0Answers: 0
edited January 2013 in General
Hi Guys,

this seems to be an easy one but i've spent quite a bit of time of it.

Just need a basic modal popup that when confirmed with post my form. if i was just linking to a site then this would be easy, but as i'm using zend framework and have to post it, i'm finding it a little harder.

I have a delete button working with out confirmation. I just use the ID, which is a hidden field in the form.

this is what I have, but I have no idea how to pass the ID to it:

[code]
var triggers = $(".modalList").overlay({

// some mask tweaks suitable for modal dialogs
mask: {
color: '#ebecff',
loadSpeed: 200,
opacity: 0.9
},
closeOnClick: false
});

var buttons = $("#yesno button").click(function(e) {

// get user input
var yes = buttons.index(this) === 0;

// do something with the answer
triggers.eq(0).html("You clicked " + (yes ? "yes" : "no"));
});
[/code]

the part below loops. I know this doesnt work.
[code]
<!-- Delete Form -->

The item will be permanently deleted and cannot be recovered. Are you sure?

<?php
$hiddenid = $this->deleterow->id;
$hiddenid->setValue(1);
echo $hiddenid;
echo $this->deleterow->delete;
?>


Yes
No




Delete?


<!-- End Delete Form -->
[/code]

Replies

  • technoicontechnoicon Posts: 12Questions: 0Answers: 0
    this is probably more of a jquery question. can someone point me to a good jquery forum?
  • allanallan Posts: 63,523Questions: 1Answers: 10,473 Site admin
    I'd suggest StackOverflow for non-DataTables related JS questions.

    Allan
This discussion has been closed.