Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Language and In...Language and In...Language Switching using URL parameterLanguage Switching using URL parameter
Previous
 
Next
New Post
3/4/2014 4:45 PM
 

Hi all

I was wondering if its possible to change the URL parameter "?Language" EG: ?Language=[locale], to something else?

I want to change it from "Language=" to "lang="

 EG: ?lang=[locale]

 Is this possible? Thx!

 
New Post
3/4/2014 7:03 PM
 
the code explicitly checks for request.querystring["language"] - we could do it but it would require amending a number of places in code and could potentially impact other modules (e.g. what happens if one is already using "lang" for something else, or one expects to read "language" to do it's own logic). You could do it by using a urlrewriting rule, and that would probably work but it's a small overhead on each page request (particularly if using siteurls.config)

Buy the new Professional DNN7: Open Source .NET CMS Platform book Amazon US
 
New Post
3/5/2014 9:40 AM
 

Thanks for your reply. The reason why I need to change the "Language" url parameter is because due our strict company policies when dealing with the naming of the URL parameters.

I am aware of the rewrite rules but I dont want it to redirect to show the "Language" url parameter in the URL address bar.

Can the rewrite rules mimic it so that it will keep the "lang" url parameter but redirect in the background?

Current:
http:// www.dnn.com/index.aspx?Language=en-CA

Needed:
http:// www.dnn.com/index.aspx?lang=en-CA

Thanks in advance,

 
New Post
3/5/2014 5:41 PM
 
the way urlrewrite works is that it rewrites what you see (in the url bar) but keeps the context the same i.e. the url would see "lang=.." but to the code it's still "language=..."

Buy the new Professional DNN7: Open Source .NET CMS Platform book Amazon US
 
New Post
3/6/2014 8:33 AM
 

Thanks for your reply. But from what I can see, the urlrewrite only does a "redirect", not a rewrite.

If I look in the SiteUrls.config file, the elements are "lookFor", and "SendTo". Is there another type that we can specified to have it rewrite instead of redirect?

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Language and In...Language and In...Language Switching using URL parameterLanguage Switching using URL parameter


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.

Content Layout

Subscribe to DNN Digest

DNN Digest is our monthly email newsletter. It highlights news and content from around the DNN ecosystem, such as new modules and themes, messages from leadership, blog posts and notable tweets. Keep your finger on the pulse of the ecosystem by subscribing.  


Copyright 2017 by DNN Corp Terms of Use Privacy
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out