function filebrowser_uninstall in Filebrowser 7.3
Same name and namespace in other branches
- 8.2 filebrowser.install \filebrowser_uninstall()
- 8 filebrowser.install \filebrowser_uninstall()
- 6.2 filebrowser.install \filebrowser_uninstall()
- 6 filebrowser.install \filebrowser_uninstall()
- 7.4 filebrowser.install \filebrowser_uninstall()
- 7.2 filebrowser.install \filebrowser_uninstall()
- 3.x filebrowser.install \filebrowser_uninstall()
File
- ./
filebrowser.install, line 98 - filbrowser installation file.
Code
function filebrowser_uninstall() {
$sql = 'SELECT nid FROM {node} n WHERE n.type = :type';
$result = db_query($sql, array(
':type' => 'dir_listing',
));
$nids = array();
foreach ($result as $row) {
$nids[] = $row->nid;
}
// http://api.drupal.org/api/function/node_delete_multiple/7
node_delete_multiple($nids);
// http://api.drupal.org/api/function/node_type_delete/7
node_type_delete('dir_listing');
}