You are here

function xmlsitemap_node_xmlsitemap_index_links in XML sitemap 7.2

Same name and namespace in other branches
  1. 6.2 xmlsitemap_node/xmlsitemap_node.module \xmlsitemap_node_xmlsitemap_index_links()

Implements hook_xmlsitemap_index_links().

1 call to xmlsitemap_node_xmlsitemap_index_links()
xmlsitemap_node_cron in xmlsitemap_node/xmlsitemap_node.module
Implements hook_cron().

File

xmlsitemap_node/xmlsitemap_node.module, line 56
Default file for XML sitemap node.

Code

function xmlsitemap_node_xmlsitemap_index_links($limit) {
  if ($types = xmlsitemap_get_link_type_enabled_bundles('node')) {
    $nids = db_query_range("SELECT n.nid FROM {node} n LEFT JOIN {xmlsitemap} x ON x.type = 'node' AND n.nid = x.id WHERE x.id IS NULL AND n.type IN (:types) ORDER BY n.nid DESC", 0, $limit, array(
      ':types' => $types,
    ))
      ->fetchCol();
    xmlsitemap_node_xmlsitemap_process_node_links($nids);
  }
}