title: How to export WordPress posts?
body: <p>How to export WordPress posts to XML or CSV? I am looking for a neat way to do it with the help of <code>PHP</code>.</p>
  
  <p><strong>Note:</strong> I don't want to do it via the admin panel because I want to automate it.</p>