function xmlsitemap_link_bundle_settings_save in XML sitemap 7.2
Same name and namespace in other branches
- 8 xmlsitemap.module \xmlsitemap_link_bundle_settings_save()
- 6.2 xmlsitemap.module \xmlsitemap_link_bundle_settings_save()
- 2.x xmlsitemap.module \xmlsitemap_link_bundle_settings_save()
Budle Settings.
8 calls to xmlsitemap_link_bundle_settings_save()
- XMLSitemapNodeFunctionalTest::setUp in xmlsitemap_node/
xmlsitemap_node.test - Setup.
- XMLSitemapUserFunctionalTest::setUp in xmlsitemap_user/
xmlsitemap_user.test - Setup.
- xmlsitemap_link_bundle_rename in ./
xmlsitemap.module - Bundle Rename.
- xmlsitemap_link_bundle_settings_form_submit in ./
xmlsitemap.module - Link bundle settings form submit.
- xmlsitemap_menu_menu_insert in xmlsitemap_menu/
xmlsitemap_menu.module - Implements hook_menu_insert().
File
- ./
xmlsitemap.module, line 1131 - xmlsitemap XML sitemap
Code
function xmlsitemap_link_bundle_settings_save($entity, $bundle, array $settings, $update_links = TRUE) {
if ($update_links) {
$old_settings = xmlsitemap_link_bundle_load($entity, $bundle);
if ($settings['status'] != $old_settings['status']) {
xmlsitemap_link_update_multiple(array(
'status' => $settings['status'],
), array(
'type' => $entity,
'subtype' => $bundle,
'status_override' => 0,
));
}
if ($settings['priority'] != $old_settings['priority']) {
xmlsitemap_link_update_multiple(array(
'priority' => $settings['priority'],
), array(
'type' => $entity,
'subtype' => $bundle,
'priority_override' => 0,
));
}
}
variable_set("xmlsitemap_settings_{$entity}_{$bundle}", $settings);
cache_clear_all('xmlsitemap:link_info:', 'cache', TRUE);
// xmlsitemap_get_link_info(NULL, TRUE);.
}