I have a very strange problem in an ASP.NET page, the following reference of JavaScript file works well in IE6
<script src='~/Scripts/xxx.js' type="text/javascript"></script>
But not working in IE7/8, I got object required error when load the page change to the following works:
<script src='<%# ResolveUrl ("~/Scripts/xxx.js") %>' type="text/javascript"></script>
Can anyone explain? Thanks.