Created
          May 10, 2017 16:25 
        
      - 
      
- 
        Save vicskf/6c549b4604614b078f1080c14bd79f39 to your computer and use it in GitHub Desktop. 
    TEC > Orders Related Events by Event Start Date
  
        
  
    
      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
    
  
  
    
  | <?php | |
| /* | |
| * Orders Related Events by Event Start Date | |
| */ | |
| function tribe_related_posts_args_limiter ( $args = array() ) { | |
| $args['meta_key'] = '_EventStartDate'; | |
| $args['orderby'] = 'meta_value'; | |
| return $args; | |
| } | |
| add_filter( 'tribe_related_posts_args', 'tribe_related_posts_args_limiter', 10, 1 ); | 
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment