function ad_image_uninstall in Advertisement 5
Same name and namespace in other branches
- 5.2 image/ad_image.install \ad_image_uninstall()
- 6.3 image/ad_image.install \ad_image_uninstall()
- 6 image/ad_image.install \ad_image_uninstall()
- 6.2 image/ad_image.install \ad_image_uninstall()
- 7 image/ad_image.install \ad_image_uninstall()
Allow complete uninstallation of the ad_image module.
File
- image/
ad_image.install, line 81
Code
function ad_image_uninstall() {
// Delete all ad_image content.
$result = db_query("SELECT aid FROM {ad_image}");
while ($aid = db_result($result)) {
node_delete($aid);
}
// Drop all ad_image module tables.
db_query('DROP TABLE {ad_image}');
db_query('DROP TABLE {ad_image_format}');
}