title: How to get WordPress menu items based on theme location as simple string/text?
body: <p>I want to show all menu and it's sub menu items form the WordPress database as simple text or string. No need to show a format. It could be object or array. </p>
  
  <p>I am using this query but don't get the menu items: </p>
  
  <pre><code>global $wpdb;
  $results = $wpdb-&gt;get_results( "SELECT * 
    FROM wp_terms AS t
    LEFT JOIN wp_term_taxonomy AS tt ON tt.term_id = t.term_id
   WHERE tt.taxonomy = 'nav_menu' ", ARRAY_A  );
  </code></pre>