Ensure new Localization HTTP module is running soon enough#4251
Merged
valadas merged 1 commit intodnnsoftware:release/9.8.0from Oct 27, 2020
Merged
Ensure new Localization HTTP module is running soon enough#4251valadas merged 1 commit intodnnsoftware:release/9.8.0from
valadas merged 1 commit intodnnsoftware:release/9.8.0from
Conversation
It needs to be right after URL Rewrite (which determines the culture from the URL), and then all modules after it can make use of that culture info
mitchelsellers
approved these changes
Oct 27, 2020
valadas
approved these changes
Oct 27, 2020
Contributor
valadas
left a comment
There was a problem hiding this comment.
Looks good to me, I'll do some localization tests on WebAPI as soon as possible too.
Contributor
valadas
added a commit
to valadas/Dnn.Platform
that referenced
this pull request
Apr 14, 2025
I did a `git bisect` which pointed me to the commits in dnnsoftware#6038 to rollup the sql scripts for v10. This made no sense to me since it's not really related to web.config and @uzmannazari pointed out in dnnsoftware#6503 that a similar issue was caused by the LocalizationModule missing from the web.config. Also I could not reproduce the issue on upgrades. Then I thought since we have that v10 rollup, it uses the 10.00.00.config for the web.config xml merge scripts and up. Investigating the commit history of that file and comparing with 9.8.0 one I found that in dnnsoftware#4251, a bugfix was done to insure that the LocalizationModule is right after the UrlRewriteModule. This means tha upon upgrades it would be in the right place but with clean installs, that would never run and it was also missing from the base web.config, thus making it not be there at all. I was debating between putting this fix in the 10.00.00.config or just in the web.config I thought the web.config is fine as upon upgrades, the order would already have been fixed (as long as we document to upgrade to latest v9 before upgrading to v10). For clean installs it would just already be at the right place to start with.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
This PR places the new Localization HTTP module right after URL Rewrite (which determines the culture from the URL), and then all modules after it can make use of that culture info. The current behavior puts it at the end for upgrades, which potentially causes issues.