function hosting_site_add_backup in Hosting 6.2
Same name and namespace in other branches
- 5 site/hosting_site.module \hosting_site_add_backup()
- 7.4 site/hosting_site.backups.inc \hosting_site_add_backup()
- 7.3 site/hosting_site.backups.inc \hosting_site_add_backup()
Add a site backup record.
Builds a list of backups of the site that have been generated.
4 calls to hosting_site_add_backup()
- hook_post_hosting_TASK_TYPE_task in ./
hosting.api.php - Perform actions when a task has completed succesfully.
- hosting_site_post_hosting_backup_task in site/
hosting_site.drush.inc - Implementation of hook_hosting_post_backup
- hosting_site_post_hosting_disable_task in site/
hosting_site.drush.inc - implementation of hook_hosting_post_disable I am not very fond of the use of bitwise operators with negatives.
- hosting_site_post_hosting_restore_task in site/
hosting_site.drush.inc - implementation of hook_hosting_post_restore I am not very fond of the use of bitwise operators with negatives.
File
- site/
hosting_site.backups.inc, line 24 - Site backup functions.
Code
function hosting_site_add_backup($site, $web_server, $filename, $description = '', $size = '') {
db_query("INSERT INTO {hosting_site_backups} (site, web_server, filename, description, size, timestamp) VALUES (%d, %d, '%s', '%s', %d, %d)", $site, $web_server, $filename, $description, $size, time());
$bid = db_last_insert_id('hosting_site_backups', 'bid');
return $bid;
}