How to include inline JS files with PHP?
<p>Normally that is how one includes JS files in HTML:</p>

<pre><code>&lt;script type="text/javascript" src="myFile.js" &gt;&lt;/script&gt;
</code></pre>

<p>But I want to write the JS file inline the HTML, using PHP; but still having the possibility of having my neat JS file, that can be chached, debugged and minified.</p>

<p>How can I do something like this?</p>

<pre><code>&lt;script&gt;
&lt;?php include 'myFile.js';?&gt;
&lt;/script&gt;
</code></pre>

<p>In other words,  how to include a JS file in HTML on the server-side. That may get a lot of advantages because it is transparent to the browser.</p>