Drupal 8 Get All Nodes Of Type

[Solved] Drupal 8 Get All Nodes Of Type | Php Frameworks Drupal - Code Explorer | yomemimo.com
Question : drupal 8 get all nodes of type

Answered by : cooperative-cormorant-hipqs32x42w2

$nids = \Drupal::entityQuery('node')->condition('type','my_custom_type')->execute();
$nodes = \Drupal\node\Entity\Node::loadMultiple($nids);

Source : https://drupal.stackexchange.com/questions/213689/get-all-nodes-of-given-type | Last Update : Sun, 19 Sep 21

Answers related to drupal 8 get all nodes of type

Code Explorer Popular Question For Php Frameworks Drupal