title: Angular and XAMPP CORS Policy
body: <p>I am trying to send some requests from my angular app to my local xampp server, but the requests are blocked due to CORS Policy.</p>
  
  <p>I have already added following line to the httpd.conf file:</p>
  
  <pre><code>Header set Access-Control-Allow-Origin *
  </code></pre>
  
  <p>I have also added an .htaccess file to my htdocs folder with following content:</p>
  
  <pre><code>Header set Access-Control-Allow-Origin *
  </code></pre>
  
  <p>I have also added this to my php file:<code>header("Access-Control-Allow-Origin: *");</code> but this had no impact as well.</p>
  
  <p>My angular app runs on <code>localhost:4200</code> and the xampp runs on <code>localhost:80</code></p>
  
  <p>I know allowing every origin is a great security issue, but it is only for testing purpose.</p>