-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SpriteVirtualPath not correctly mapped #189
Comments
I have managed to get it working by setting the paths as following; RequestReduce.Api.Registry.Configuration.SpritePhysicalPath = HostingEnvironment.MapPath("~/repository/cache");
RequestReduce.Api.Registry.Configuration.SpriteVirtualPath = Utility.ResolveUrl("~/repository/cache"); Utility.ResolveUrl is a custom method which resolves relative to absolute url. |
Shouldn't the Configuration properties behave in the same way as the properties in web.config? |
hard to argue that. yes. |
Could this problem be the same problem as #191? |
This is most likely unrelated. The problem was that the SpriteVirtualPath was being translated to the absolute path at initialization of the configuration and never again. So passing in new values through the API were not resolving the tilde. |
When not using the web.config, but WebActivator.PreApplicationStartMethod to configure and initialize RequestReduce, something goes wrong with the output path of the resources.
The code:
The output in the HTML becomes:
~/repository/cache/4556dbb543035982a75b0059a0806b18-6db26c880265f8bd42293e18e1fea26a-RequestReducedScript.js
(should be absolute url)
Though the files are correctly combined and minified and stored to the specified path.
The text was updated successfully, but these errors were encountered: