You are here

function _publication_date_update_existing in Publication Date 6

Same name and namespace in other branches
  1. 8.2 publication_date.install \_publication_date_update_existing()
  2. 8 publication_date.install \_publication_date_update_existing()
  3. 7.2 publication_date.install \_publication_date_update_existing()
  4. 7 publication_date.install \_publication_date_update_existing()

Function to update the existing nodes on install so sorting will work properly.

1 call to _publication_date_update_existing()
publication_date_install in ./publication_date.install
Implementation of hook_install().

File

./publication_date.install, line 66
@author Clever Age @author Emmanuelle Gouleau @author Tristan Marly

Code

function _publication_date_update_existing() {
  $sql = "INSERT INTO {publication_date} SELECT nid,created FROM {node} where status = 1";
  db_query($sql);
}