0

I got a bundling problem in my release-mode on IIS7 (Asp.net mvc 4)

in my BundleConfig:

 var vTickerJs = new ScriptBundle("~/Scripts/vtickerjs").Include(
            "~/Scripts/vticker/jquery.vticker.*"
            );
        bundles.Add(vTickerJs);

In my Partial:

 @Scripts.Render("~/Scripts/vtickerjs")

on my Harddisk:

 E:....\Scripts\vticker\jquery.vticker.js

There is a difference between IIS-Express on my local system - Here it works and the above mentioned Partial has:

<script src="/Scripts/vtickerjs?v=-d007Ef_5pa18P48liUylZoCJuP69zO53AEJrSmBH841"></script>

BUT on my IIS-7 the same code renders as:

<script src="/Scripts/vtickerjs"></script>

giving 404 not found.

I DONT have a "Scripts\vtickerjs" folder on my disk

reinhard
  • 818
  • 1
  • 10
  • 24

1 Answers1

0

Try this,

 bundles.Add(new ScriptBundle("~/bundles/vtickerjs").Include(
        "~/Scripts/vticker/jquery.vticker*"

  @section scripts {  
     @Scripts.Render("~/bundles/vtickerjs")
}

If youn use BundleConfig then use bundles instead of Scripts

Jaimin
  • 7,964
  • 2
  • 25
  • 32