I have to load nodes of certain content type that are published.
Any built in function already available for this purpose?
Drupal Answers is a question and answer site for Drupal developers and administrators. It only takes a minute to sign up.
Sign up to join this communityI have to load nodes of certain content type that are published.
Any built in function already available for this purpose?
To load a bunch of nodes based on custom parameters, you have to use EntityFieldQuery. It replaces the $conditions
array noad_load_multiple
used.
$nodes = node_load_multiple(array_keys($result['node']));
As shown here: drupal.stackexchange.com/questions/3/…
– Junaid
Apr 3 '12 at 8:26