Created
September 21, 2016 19:47
-
-
Save seanbuscay/b932ec904ad890f9f706326c7dd219c5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$query = new EntityFieldQuery(); | |
$query->entityCondition('entity_type', 'node') | |
->propertyCondition('status', 1) | |
->propertyCondition('type', array('article', 'page', 'blog')) | |
->propertyOrderBy('created', 'DESC') | |
->range(0, 5); | |
$result = $query->execute(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment