title: Usage of esc_url, esc_html, esc_attr ... functions
body: <p>When are definitely needed or for a good practice to use escaping functions?</p>
  
  <p>Such as using <code>esc_url();</code> with:</p>
  
  <pre><code>get_template_directory_uri();
  get_permalink();
  get_author_posts_url();
  get_edit_post_link();
  wp_get_attachment_url();
  </code></pre>
  
  <p>And <code>esc_html();</code> with:</p>
  
  <pre><code>get_the_title();
  get_the_author();
  get_the_date();
  get_search_query();
  </code></pre>
  
  <p>Also I think <code>esc_html();</code> and <code>esc_attr();</code> are very similar, aren't they?  What are the differences?</p>