title: using composer and autoload in wordpress theme, 'Failed opening required'
body: <p>So I've installed createsend-php for my theme via composer (I'm trying to learn how too use it) but can't get to the next stage.</p>
  
  <p>I can see the API here -
  <code>/wp-content/themes/wonkhe2-theme/vendor/campaign-monitor/createsend-php/</code></p>
  
  <p>composer file seems right to me -</p>
  
  <pre><code>  "require": {
      "php": "&gt;=5.4.0",
      "composer/installers": "~1.0",
      "campaignmonitor/createsend-php": "&gt;=6.0"
    }
  </code></pre>
  
  <p>in /wp-content/themes/wonkhe2-theme/templates/content-signup-cm.php I've added
  <code>require_once 'csrest_campaigns.php'</code></p>
  
  <p>And that returns</p>
  
  <pre><code>Fatal error: require_once(): Failed opening required 'csrest_campaigns.php' (include_path='.:/Applications/MAMP/bin/php/php7.2.7/lib/php') in /wp-content/themes/wonkhe2-theme/templates/content-signup-cm.php on line 5
  </code></pre>
  
  <p>Should the require_once path be different? I thought autoloader would set the paths and namespaces. </p>
  
  <p>Using composer is new to me so apologies if I'm misunderstanding but any help appreciated.</p>