1

I am using bootstrap in my asp.net form application. I have all the required files in the project:

  • bootstrap.min.js
  • jquery-2.0.3.min.js
  • bootstrap.min.css

When I add a content page in the root directory , the site work perfectly; all the bootstrap features work correctly. But the problem is, when I place content in another folder (eg. webapp/content/default.aspx), the site does not work in IE. On other browsers it displays the content but the features of bootstrap don't work at all.

My scripts:

<script src="js/jquery-2.0.3.min.js"></script>
<script src="js/bootstrap.min.js"></script>
</body>

3 Answers 3

1

JQuery 2.0.x is not compatable with some of the older browsers. Use the latest 1.9.x

See http://www.sitepoint.com/jquery-2-support-ie6-ie7-ie8/

Sign up to request clarification or add additional context in comments.

1 Comment

isn't ~ a server side concept?
0
**Try using the files:**
ie8-responsive-file-warning.js,
html5shiv.js and 
respond.min.js.

Make the Downloads and place the files in js folder.

**Use the paths**

    "@Url.Content("~/patch/file.js")"



     ****Example****


    <head>
        <!-- Just for debugging purposes. Don't actually copy this line! -->
        <!--[if lt IE 9]><script src="@Url.Content("~/js/ie8-responsive-file-warning.js")"></script><![endif]-->

        <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
        <!--[if lt IE 9]>
          <script src="@Url.Content("~/js/html5shiv.js")"></script>
          <script src="@Url.Content("~/js/respond.min.js")"></script>
        <![endif]-->

        <script src="@Url.Content("~/js/jquery-2.0.3.min.js")"></script>
        <script src="@Url.Content("~/js/bootstrap.min.js")"></script>

      </head>

Comments

0

You need a / as in

<script src="/js/jquery-2.0.3.min.js"></script>
<script src="/js/bootstrap.min.js"></script>

To be more complete

  1. starting with a slash makes it relative to the root website directory
  2. Two periods ../ would make it go up one directory (so ../../ makes it go up two directories ...)
  3. ~/ takes you to the root of your project directory.
  4. otherwise it is relative to the directory the current file is in. (so js/jquery-2.0.3.min.js is looking for the file in a js subfolder of your current dir.)

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.