how do i reference my script properly so when deployed application won’t have a problem finding it?
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js "></script>
<script type="text/javascript" src="/Public/Scripts/jqModal.js"></script>
<script type="text/javascript" src="http://maps.googleapis.com/maps/api/js?sensor=true"></script>
I’m using VS2008 Web Forms
I keep getting warnings saying:
Warning 3 Error updating JScript IntelliSense: C:\Documents and Settings\myusername\Local Settings\Temporary Internet Files\Content.IE5\2N4L8DWB\jquery.min-fds90[1]..js: Object doesn’t support this property or method @ 1:17179 C:\Applications\xxx\xxx\index.aspx 1 1
You could use the
ResolveUrlmethod for scripts that are local to your application:The other 2 scripts are absolute urls referenced from external CDNs so they should be fine and you should leave them as is.
As far as the warning is concerned, simply ignore it. Visual Studio Intellisense in web pages is far from perfect. FWIW in VS2010 it’s no better. Hopefully they will fix it in vNext.