1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / Developing with Sitefinity / Intra-site Module Public Page Group

Intra-site Module Public Page Group

4 posts, 0 answered
  1. Pratik
    Pratik avatar
    2 posts
    Registered:
    04 Jul 2011
    01 Aug 2011
    Link to this post
    Hi

    I've am trying out building custom modules with sitefinity 4.1 sp2. I followed the video by Josh Morales on creating an intra-site page based module. I have couple of questions:
    1. Is there a way to create a page group for public pages. Meaning, there is one landing public page and other pages are a part of the group. I realize that we can create separate public pages but the reason I would prefer to have other pages in a group is that I do not want the users to navigate directly to a public page. I believe that page groups can be created in admin section.
    2. Page Navigation Url: I found that we can get the current PageSiteNode's Url using ResolveUrl(Telerik.Sitefinity.Web.SiteMapBase.GetActualCurrentNode().Url). Is there a way to get some other page's Url the same way?

    Thanks
    Pratik
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    02 Aug 2011
    Link to this post
    Hi Pratik,

    1. You can create page groups fro the backend of frontend and there is no difference between both the types except that one will be used only on the frontend and another on the backend. Programmatically you can use

    CreatePage(PageLocation pageLocation, Guid pageId, NodeType nodeType) method of the PageManager or fluent API - App.WorkWith.Page()

    2. You can use PageNode and its Urls property.



    Regards,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Pratik
    Pratik avatar
    2 posts
    Registered:
    04 Jul 2011
    04 Aug 2011
    Link to this post
    Hi Ivan

    thanks for your quick response. I will try the CreatePage option soon for point 1. For point 2, I found something like this
    var fluent = App.WorkWith().Pages();
     //get a page by its Title
     var mypage = fluent.LocatedIn(Telerik.Sitefinity.Fluent.Pages.PageLocation.Frontend).Where(
     pg => pg.Page.Title == "Products").Get().FirstOrDefault();
    ResolveUrl(mypage.GetFullUrl());
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    05 Aug 2011
    Link to this post
    Hello Pratik,

    This is the same, the difference is that you use the fluent API which calls the standard in its basis.

    Greetings,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
4 posts, 0 answered