Created
          September 23, 2013 10:56 
        
      - 
      
 - 
        
Save jamesmorrish/6668996 to your computer and use it in GitHub Desktop.  
    Example entity field query including language.
  
        
  
    
      This file contains hidden or 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('type', 'blog') | |
| ->propertyCondition('status', 1) | |
| ->propertyOrderBy('created', 'DESC') | |
| ->fieldCondition('field_journal_carousel_image', 'fid', 0, '!=') | |
| ->range(0, 10); | |
| $query->propertyCondition('language', array($GLOBALS['language']->language, LANGUAGE_NONE), 'IN'); | |
| $result = $node_query->execute(); | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment