You are here

function og_panels_delete_confirm in Organic groups 6

Same name and namespace in other branches
  1. 5.8 og_panels.module \og_panels_delete_confirm()
  2. 5 og_panels.module \og_panels_delete_confirm()
  3. 5.3 og_panels.module \og_panels_delete_confirm()
  4. 5.7 og_panels.module \og_panels_delete_confirm()
1 string reference to 'og_panels_delete_confirm'
og_panels_menu in modules/og_panels/og_panels.module

File

modules/og_panels/og_panels.module, line 134

Code

function og_panels_delete_confirm($did, $group_node) {
  $form['did'] = array(
    '#type' => 'value',
    '#value' => $did,
  );
  $form['nid'] = array(
    '#type' => 'value',
    '#value' => $group_node->nid,
  );
  $sql = "SELECT page_title FROM {og_panels} WHERE did = %d";
  $page_title = db_result(db_query($sql, $did));
  $form['page_title'] = array(
    '#type' => 'value',
    '#value' => $page_title,
  );
  return confirm_form($form, t('Are you sure you want to delete %title?', array(
    '%title' => $page_title,
  )), isset($_GET['destination']) ? $_GET['destination'] : 'node/' . $node->nid . 'og_panels', t('This action cannot be undone.'), t('Delete'), t('Cancel'));
}