Possible Duplicate:
Why don't self-closing script tags work?
I just found a weired behavior with the script tag in HTML.
I web server is nginx, and I used FAST CGI and PHP5. I have a page.html, which looks like this:
<html>
<body>
<!-- <?php echo 'i am going to add php code here'; ?> -->
<script type="text/javascript" src="./my/javascript1.js" />
<script type="text/javascript" src="./my/javascript2.js" />
</body>
</html>
If this page is served directly from the web server, the java script works well. But if it passed to PHP5, it seems only the first java script tag is executed. But if I change the script block into:
<script type="text/javascript" src="./my/javascript1.js"></script>
<script type="text/javascript" src="./my/javascript2.js"></script>
Everything works again. Noticed how the tags are closed? Yeah, that is why I am asking here. What is the difference? They are supposed to have the same function/meaning. Besides, the output HTML that my web browser (Chrome/IE9) received are the same, but why treated differently?