More in this section

Forums / Developing with Sitefinity / page group in sitemenu.ascx and language switching

page group in sitemenu.ascx and language switching

12 posts, 0 answered
  1. Richard van der Helm
    Richard van der Helm avatar
    32 posts
    Registered:
    29 Oct 2005
    08 Jul 2007
    Link to this post
    Hi,

    im using the sitemenu.ascx in a template. The site is multilanguage. In the default language a pagegroup en its childs items show in the menu. In a non-default the page group does not show and neither the child items.

    Second problem with multilanguage and menu. If i place a language bar on a template and i switch to another language in live site the menu en panelbar are not uodate with the new language and url. Work around this with turning viewstate to false for these controls, but doen't no for sure of this is by design.

    best regards,

    Richard van der Helm
  2. Slavo
    Slavo avatar
    295 posts
    Registered:
    24 Sep 2012
    09 Jul 2007
    Link to this post
    Hi richard van der Helm,

    The only situation in which I could reproduce this behavior is when the persistenceMode attribute for localization is set to Session. For the moment, the only values, for which multilingual support is implemented are PathPrefix and QueryString. Try setting the value of persistenceMode to one of these and let me know if the problem still occurs.

            <localization defaultProvider="Sitefinity" persistenceMode="QueryString" defaultCulture="en" cultures="en, es, fr, de, bg">  
                <providers> 
                    <clear/> 
                    <add name="Sitefinity" type="Telerik.Localization.Data.DefaultProvider, Telerik.Localization.Data" connectionStringName="DefaultConnection"/>  
                </providers> 
            </localization> 


    Greetings,
    Slavo
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. Richard van der Helm
    Richard van der Helm avatar
    32 posts
    Registered:
    29 Oct 2005
    09 Jul 2007
    Link to this post
    The persistenceMode  is already in pathprefix. Therefor problem still occurs. Please let me know if you need more information.

    best regards,

    Richard
  4. Slavo
    Slavo avatar
    295 posts
    Registered:
    24 Sep 2012
    09 Jul 2007
    Link to this post
    Hi richard van der Helm,

    I reproduced your problem, again in a particular situation. This is what I did:

    I created a template with a Site Menu and a Language Bar in it.
    I created three pages - Parent 1, Child 1 (subpage of parent 1) and parent 2 and set them to use the newly created template. I then changed Parent 1 from normal to a group page. Then I added 2nd language versions (Bulgarian in my case) of all pages, and copied the content from their English language versions.
    When I changed the language in the live site, parent 1 and child 1 did not show in the menu.

    After a while I found what caused this behavior. When you create a different language version of a group page, the new page does not have a template. This can be seen in the list of all pages. I then changed the new page to normal. Edited it and changed the template, then switched back to group page. The problem was solved.

    Please try and set the template of your page groups explicitly for the different language versions. This should solve your problem. If not, it would be helpful if you send us a project where we can observe the behavior you are talking about.

    All the best,
    Slavo
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  5. Richard van der Helm
    Richard van der Helm avatar
    32 posts
    Registered:
    29 Oct 2005
    09 Jul 2007
    Link to this post
    Thnks Slavo,

    this solves it. I don't know for sure wether it has to do with no template set. I think it's more of a workflow issue after following your directions. When you create a page as pagegroup you get the normal flow. (draft etc)  If  you then create the page via add language in a different language the page shows as published immediatly, although in database it is probably set as draft and there for it does not show.

    Just one other question: In a template page i would like to create some localizable text. Do i do that by adding a generic content bloc to the template(don't think so because there doesn't  seem to be any language features in template) or do i set this by using the default asp.net localization techniques in the masterpage directly.(i hope not caus i like the fact that with templates you can derive multiple templates from one masterpage.?

    Great product by the way.

    regards,

    Richard
  6. Slavo
    Slavo avatar
    295 posts
    Registered:
    24 Sep 2012
    10 Jul 2007
    Link to this post
    Hello richard van der Helm,

    Thank you for the good words.
    Yes, you are right. It seems more like a workflow issue. The problem was that the status of the page was set to new when creating a new language version, instead of published. We have fixed this for the next release. For now you can employ the workaround mentioned by changing the page type from group to normal and back.

    About your second question:
    The templates do not have different versions for every language - it is one for all. However, there is still a way to put some localizable content in a template, because the Generic Content module is localizable. Here is how to do it:

    1. In your web.config enable localization for generic content in the provider for generic content:
        
    <cmsEngine defaultProvider="Generic_Content">  
        <providers> 
            <clear/> 
            <add name="Generic_Content" visible="True" defaultMetaField="Name" securityProviderName="" allowLocalization="True" allowVersioning="True" allowWorkflow="False" versioningProviderName="" connectionStringName="GenericContentConnection" type="Telerik.Cms.Engine.Data.Providers.DefaultProvider, Telerik.Cms.Engine.Data" listTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/ControlPanelList.ascx" insertTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/ControlPanelInsert.ascx" editTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/ControlPanelEdit.ascx" permissionsTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/ControlPanelPermissions.ascx" commandPanelTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/CommandPanel.ascx" editorTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/EditorTemplate.ascx" shareContentDialogTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/NewContentDialog.ascx" selectContentDialogTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/SelectContentDialog.ascx" contentVersionViewUrl="~/Sitefinity/Admin/ControlTemplates/GenericContent/ContentVersionView.aspx" commentsListTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/CommentsList.ascx" commentsEditTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/CommentsEdit.ascx" commentsListPublicTemplate="~/Sitefinity/ControlTemplates/GenericContent/CommentsList.ascx" contentSelectorTemplate="~/Sitefinity/Admin/ControlTemplates/GenericContent/ContentSelector.ascx" allowComments="false" commentsModeration="true"/>  
            ...  
        </providers> 
    ...  
    </cmsEngine> 

    2. Go to Modules -> Generic Content and create a new content item.
    3. Create different language versions for this content item by changing the language from the language bar in the top-right corner and editing the corresponding version.
    3. In the template, drop a generic content control, edit it and select the "Select shared content" option.
    4. Find the content you created in Modules -> Generic Content.

    Now when changing the language, your content will show the corresponding language version.
    If you have any other questions, please don't hesitate to ask.

    Greetings,
    Slavo
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  7. Richard van der Helm
    Richard van der Helm avatar
    32 posts
    Registered:
    29 Oct 2005
    10 Jul 2007
    Link to this post
    Hi Slavo,

    I'm kind of having the same problems with the singlenews control as i had with the page group. Ik configured the news module, author and summary field to localizable in the web config. If i view an article in a page with a singlenews control i can see the the summary and author field localized but the content stays blank, although in admin it states published. I can only view the content in the last saved language.

    I've turned workflow on for the news module but that didnt help either.

    Hope you can help
  8. Slavo
    Slavo avatar
    295 posts
    Registered:
    24 Sep 2012
    12 Jul 2007
    Link to this post
    Hi Richard,

    Thank you for reporting this issue. Actually it was not related to group pages. The problem was with the localization of generic content and modules based on it. It has been fixed now and you can create different language versions for ceneric content, news and blogs in your pages. You will be able to download Service Pack 2 later today or tomorrow.

    Best wishes,
    Slavo
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  9. Richard van der Helm
    Richard van der Helm avatar
    32 posts
    Registered:
    29 Oct 2005
    18 Jul 2007
    Link to this post
    Hi,

    i'm still having problems in showing the localized content(stays blank part of news after applying the sp2 (copied files in zip to folders) and using the singlenews control. The title etc do localize only the content stays blank in the default language.   Can you tell me how the settings should be.

    regards,

    Richard
  10. Slavo
    Slavo avatar
    295 posts
    Registered:
    24 Sep 2012
    18 Jul 2007
    Link to this post
    Hi richard van der Helm,

    Thank you for reporting this. We found the problem. It only occurs when localizing metadata, as in your case. The localization of metadata corrupted the content itself and it was not saved to the database. This is the reason why it did not occur for generic content, and only upon saving a news item. If you rely on this and need it urgently to implement a product, we can send you a hotfix.

    Best wishes,
    Slavo
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  11. Richard van der Helm
    Richard van der Helm avatar
    32 posts
    Registered:
    29 Oct 2005
    20 Jul 2007
    Link to this post
    Hi Slavo,

    I do not rely on it immediatly. I've planned it will take me a month or so to get our entire site up and running using sitefinity. So it kind of depends on when you're planning to get the next sp out .

    thnx and regards

    Richard
  12. Rebecca
    Rebecca avatar
    536 posts
    Registered:
    24 Sep 2012
    20 Jul 2007
    Link to this post
    Hello richard van der Helm,

    Sitefinity 3.1 is scheduled for mid September. If you later decide that you need the hotfix, do let us know.

    Regards,
    Rebecca
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Register for webinar
12 posts, 0 answered