locked
Setting the Locale from a stapling feature RRS feed

  • Question

  • Hi,

    When I create a My Site, I'd like to automatically change the default "English (United States)" Locale to "English (United Kingdom)". I've created a stapling feature to do things like site the site's theme. I was hoping to add Locale code, such as...

    curWeb.Locale = CultureInfo.CreateSpecificCulture("en-GB");
    curWeb.Update();

    or

    curWeb.Locale = new CultureInfo("en-GB");
    curWeb.Update();

    But the locale isn't being set correctly. Anyone had experience of this area, or any solutions? Many thanks in advance.
    Monday, October 5, 2009 11:25 AM

Answers

  • I can find the Regional Settings for the "My Site" site collection, but not the host application. E.g. My Site has the URL http://spudulike.com/personal/bob/default.aspx - there's no host site at http://spudulike.com/personal or http://spudulike.com

    How can I access the Regional Settings in the MySite host application? Is it via SSP or central admin?

    Ta for replying.


    Yes there is a site at http://spudulike.com .. it's the "MySite Host" site definition, which includes automatic redirects to the current user's My Site.

    Try navigating to http://spudulike.com/_layouts/settings.aspx

    PS - /personal/ isn't a site, it's a managed path, in which all of the "My Site" site collections are created.
    regards
    Martin Hatch
    MCPD .Net Web Development
    MCTS WSS 3.0 | MOSS 2007
    Visit my Blog
    • Marked as answer by Gazz1e Monday, October 5, 2009 2:35 PM
    Monday, October 5, 2009 2:16 PM

All replies

  • Change the Regional Settings in the MySite Host application.

    When a new MySite is created it automatically picks up the regional settings from the host site (and the branding settings too!).
    regards
    Martin Hatch
    MCPD .Net Web Development
    MCTS WSS 3.0 | MOSS 2007
    Visit my Blog
    • Proposed as answer by Dave Hunter Monday, October 5, 2009 12:55 PM
    Monday, October 5, 2009 12:41 PM
  • I can find the Regional Settings for the "My Site" site collection, but not the host application. E.g. My Site has the URL http://spudulike.com/personal/bob/default.aspx - there's no host site at http://spudulike.com/personal or http://spudulike.com

    How can I access the Regional Settings in the MySite host application? Is it via SSP or central admin?

    Ta for replying.

    Monday, October 5, 2009 2:13 PM
  • I can find the Regional Settings for the "My Site" site collection, but not the host application. E.g. My Site has the URL http://spudulike.com/personal/bob/default.aspx - there's no host site at http://spudulike.com/personal or http://spudulike.com

    How can I access the Regional Settings in the MySite host application? Is it via SSP or central admin?

    Ta for replying.


    Yes there is a site at http://spudulike.com .. it's the "MySite Host" site definition, which includes automatic redirects to the current user's My Site.

    Try navigating to http://spudulike.com/_layouts/settings.aspx

    PS - /personal/ isn't a site, it's a managed path, in which all of the "My Site" site collections are created.
    regards
    Martin Hatch
    MCPD .Net Web Development
    MCTS WSS 3.0 | MOSS 2007
    Visit my Blog
    • Marked as answer by Gazz1e Monday, October 5, 2009 2:35 PM
    Monday, October 5, 2009 2:16 PM
  • Thanks Martin.

    Don't suppose you know how to change "Organization Hierarchy" (US) to "Organisation Hierarchy" (UK) in "My Profile"?
    Monday, October 5, 2009 2:36 PM
  • The "My Profile" page actually runs from the "My Site Host" site right down at the root site. You will notice that it has a different URL from your actual "My Site".

    for example:

    My Profile URL
    http://mysite/Person.aspx?accountname=martinhatch

    My Site URL
    http://mysite/personal/martinhatch/


    If you want to change anything on that page you need to do it from the "My Site Host" because it is all centrally managed.

    The actual ASPX page is sat in the My Site Host site definition:

    ..\12\Template\SiteTemplates\spsmsitehost\Person.aspx

    I wouldn't recommend directly changing that file though, because then your system won't be in a supported state :)
    regards
    Martin Hatch
    MCPD .Net Web Development
    MCTS WSS 3.0 | MOSS 2007
    Visit my Blog
    Monday, October 5, 2009 2:49 PM
  • Thanks again Martin :))

    I assume it's okay to change Person.aspx with in SharePoint designer (making it a ghosted page?), and still be supported by MS.
    Monday, October 5, 2009 3:04 PM
  • Yes, that will only change the version stored in the Content Database.

    you can always go to Site Settings on the My Site Host and do a "reset to site definition".
    regards
    Martin Hatch
    MCPD .Net Web Development
    MCTS WSS 3.0 | MOSS 2007
    Visit my Blog
    Monday, October 5, 2009 3:06 PM