You are here

function smileys_import_delete in Smileys 5

Same name and namespace in other branches
  1. 6 smileys_import.module \smileys_import_delete()

Menu callback; Delete a Smiley pack.

1 call to smileys_import_delete()
smileys_import_add in ./smileys_import.module
Menu callback; Add a Smiley pack.
1 string reference to 'smileys_import_delete'
smileys_import_menu in ./smileys_import.module
Implementation of hook_menu().

File

./smileys_import.module, line 147

Code

function smileys_import_delete($packname, $redirect = 0) {
  $pack = $packname ? $packname : arg(5);
  db_query("DELETE FROM {smileys} WHERE package = '%s'", $pack);
  if ($redirect == 0) {
    drupal_set_message(t('Smiley package %pack uninstalled.', array(
      '%pack' => $pack,
    )));
    drupal_goto('admin/settings/smileys/import');
  }
}