Skip to main content
added 32 characters in body
Source Link
Oswald
  • 4.9k
  • 17
  • 22

Whether nodes of a particular content type are promoted to the front page by default areis stored in the Drupal array variable node_options_{content type name}:

$options$node_options = variable_get('node_options_{content type name}', array());
$promote$promote_key = array_search('promote', $options$node_options);
if ($promote$promote_key !== false) {
  unset($options[$promote]$node_options[$promote_key]);
  variable_set('node_options_{content type name}', $options$node_options);
}

Whether nodes are promoted to front page by default are stored in the Drupal array variable node_options_{content type name}:

$options = variable_get('node_options_{content type name}', array());
$promote = array_search('promote', $options);
if ($promote !== false) {
  unset($options[$promote]);
  variable_set('node_options_{content type name}', $options);
}

Whether nodes of a particular content type are promoted to the front page by default is stored in the Drupal array variable node_options_{content type name}:

$node_options = variable_get('node_options_{content type name}', array());
$promote_key = array_search('promote', $node_options);
if ($promote_key !== false) {
  unset($node_options[$promote_key]);
  variable_set('node_options_{content type name}', $node_options);
}
Source Link
Oswald
  • 4.9k
  • 17
  • 22

Whether nodes are promoted to front page by default are stored in the Drupal array variable node_options_{content type name}:

$options = variable_get('node_options_{content type name}', array());
$promote = array_search('promote', $options);
if ($promote !== false) {
  unset($options[$promote]);
  variable_set('node_options_{content type name}', $options);
}