Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

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...System Default LanguageSystem Default Language
Previous
 
Next
New Post
5/29/2012 6:46 AM
 

Hello!

    I read in another post that system default language must be en-US. I did some digging and found that this is because the system default language is hard-coded in many methods and class members, including  Localization class member SystemLocale.

Now I have the following problem: I've upgraded my site to DNN 6.1.5. Site works fine, but: I wanted to export the site template to create a subportal and clone the site, and noticed that the choose site dropdown didn't populate. It turns out that this is because the GetPortals stored procedure needs a cultureCode parameter, which is always en-US. Below is the method that should return the list of portals so I can choose which to export.

public ArrayList GetPortals()
        {
            string cultureCode = Localization.SystemLocale;
            string cacheKey = String.Format(DataCache.PortalCacheKey, Null.NullInteger, cultureCode);
            var portals = CBO.GetCachedObject<List<PortalInfo>>(new CacheItemArgs(cacheKey, DataCache.PortalCacheTimeOut, DataCache.PortalCachePriority, cultureCode),
                                                    GetPortalsCallBack);
            return new ArrayList(portals);
        }

Notice the line in bold.

Now here is that property in Localization class:

public static string SystemLocale
        {
            get
            {
                return "en-US";
            }
        }

So the problem is that all of my portals have en-GB culture, whereas the parameter is always en-US for the GetPortals method. Is there a workaround for this?

 
New Post
5/29/2012 7:02 AM
 
I think, you are misunderstanding sth. system default language is used for cache to specify "neutral" language for cached items. This is not related to UI elements.

Cheers from Germany,
Sebastian Leupold

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group

Speed up your DNN Websites with TurboDNN
 
New Post
5/29/2012 8:13 AM
 
Hi Sebastian, thanks for the reply. The thing is, when I changed the stored procedure to return the portals that have en-GB as culture code, the portal dropdown list populated without problems. This is why I checked where this stored procedure is called when clicking export site, and I found what I initially posted.
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Language and In...Language and In...System Default LanguageSystem Default Language


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.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out