title: Wordpress Query to fetch both posts and pages by a custom field/key
body: <p>I am working on a slider where I will show some contents(featured image and excerpt) pulled from both posts and pages. I want to filter the posts/pages by a custom field called 'slider'! </p>
  
  <p>So if there are some pages and posts with 'slider' custom field only those will appear in the slider. Is it possible in wordpress? If it is then how? </p>
  
  <p>Some guidance will be appreciated!</p>