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

Forums / Developing with Sitefinity / Multiple Blog Post control on One Page

Multiple Blog Post control on One Page

10 posts, 1 answered
  1. Muhammad Saqib
    Muhammad Saqib avatar
    95 posts
    Registered:
    09 Sep 2009
    24 Nov 2009
    Link to this post
    Hi,

    I want to show multiple blog post control on the same page, each control displays different blog.
    My idea is to show controls under RadTabStrip .i.e On each tab a different control will be displayed.
    What i have done is to create a RadTabStrip and MultiPage view on my master page and added a Content PlaceHolder on each PageView.
    But there are couple of problems.

    1. I am not been able to shift to other tab in edit mode(admin panel) so that i can drag blog post control.
    2. when i add 2 blog post control on one page, the following exception occurs when i preview the page.

    Multiple controls with the same ID 'link' were found. FindControl requires that controls have unique IDs.



    Can someone please help me to find good solution
    Thanks
  2. Muhammad Saqib
    Muhammad Saqib avatar
    95 posts
    Registered:
    09 Sep 2009
    25 Nov 2009
    Link to this post
    Can anyone please help me with the following error when i post more than 1 BlogPost control on the same page

    Multiple controls with the same ID 'link' were found. FindControl requires that controls have unique IDs. 


  3. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    25 Nov 2009
    Link to this post
    Hi Muhammad Saqib,

    The error says that you use two control with the same ID.

    Try using the following declaration for your RadTabStrip and RadMultiPage. I tried adding several BlogPosts controls and everything was working fine.

    <head runat="server">
        <title></title>
        <asp:ContentPlaceHolder id="head" runat="server">
        </asp:ContentPlaceHolder>
    </head>
    <body>
        <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server" />
        <div>
          <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">
           <telerik:RadTabStrip ID="RadTabStrip1" runat="server" MultiPageID="MultiPage1" Skin="Outlook">
            <Tabs>
             <telerik:RadTab runat="server" PageViewID="RadPageView1" Text="Tab1" Selected="true"></telerik:RadTab>
             <telerik:RadTab runat="server" PageViewID="RadPageView2" Text="Tab2"></telerik:RadTab>
             <telerik:RadTab runat="server" PageViewID="RadPageView3" Text="Tab3"></telerik:RadTab>
            </Tabs>
           </telerik:RadTabStrip>
            <telerik:RadMultiPage runat="server" ID="MultiPage1">
                <telerik:RadPageView runat="server" ID="RadPageView1" >
                <asp:ContentPlaceHolder ID="Holder1" runat="server" />
                </telerik:RadPageView>
                <telerik:RadPageView runat="server" ID="RadPageView2">
                <asp:ContentPlaceHolder ID="ContentPlaceHolder2" runat="server" />
                </telerik:RadPageView>
                <telerik:RadPageView
                 <asp:ContentPlaceHolder ID="ContentPlaceHolder3" runat="server" />
                </telerik:RadPageView>
          </telerik:RadMultiPage>
          </asp:ContentPlaceHolder>
           
        </div>
        </form>
    </body>
    </html>

    Greetings,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  4. Muhammad Saqib
    Muhammad Saqib avatar
    95 posts
    Registered:
    09 Sep 2009
    25 Nov 2009
    Link to this post
    It worked!!.. But a problem...
    I can't add /edit the controls in Edit Mode....
  5. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    25 Nov 2009
    Link to this post
    Hi Muhammad Saqib,

    Have you tried the suggestion from the previous post? You should add css and style RadPageView control to make all mulitapges accessible. You should add a CssClass and use display: block property. You could add your css class to ~/Sitefinity/Admin/Themes/Default/PageEditor.css and ~/Sitefinity/Admin/Themes/Default/PageEditorOverlay.css( for overlay mode)

    Sincerely yours,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  6. Muhammad Saqib
    Muhammad Saqib avatar
    95 posts
    Registered:
    09 Sep 2009
    25 Nov 2009
    Link to this post
    Yes i did, like this...

    <telerik:RadMultiPage runat="server" ID="MultiPage1"
                <telerik:RadPageView runat="server" ID="RadPageView1" CssClass="RadCSS" > 
                <asp:ContentPlaceHolder ID="ContentPlaceHolder2" runat="server" /> 
                </telerik:RadPageView> 
                <telerik:RadPageView runat="server" ID="RadPageView2" CssClass="RadCSS"
                <asp:ContentPlaceHolder ID="ContentPlaceHolder2_1" runat="server" /> 
                </telerik:RadPageView> 
                <telerik:RadPageView runat="server" ID="RadPageView3" CssClass="RadCSS"
                 <asp:ContentPlaceHolder ID="ContentPlaceHolder2_2" runat="server" /> 
                </telerik:RadPageView> 
          </telerik:RadMultiPage> 

    and in PageEditor.css file i added this.

    .RadCSS 
        display:block;  

    Did'nt work,,,,,

    Even with this..

    .RadCSS 
        display:block !important;  


  7. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    16 Jun 2017
    25 Nov 2009
    Link to this post
    Hi Muhammad Saqib,

    Here is the declaration I use and the css added

    <div id="SideBar"><asp:contentplaceholder id="SideBarContent" runat="server">
             
            <telerik:RadTabStrip ID="RadTabStrip1" runat="server" MultiPageID="MultiPage1" Skin="Outlook">
            <Tabs>
             <telerik:RadTab runat="server" PageViewID="RadPageView1" Text="Tab1" Selected="true" ></telerik:RadTab>
             <telerik:RadTab runat="server" PageViewID="RadPageView2" Text="Tab2" ></telerik:RadTab>
             <telerik:RadTab runat="server" PageViewID="RadPageView3" Text="Tab3" ></telerik:RadTab>
            </Tabs>
           </telerik:RadTabStrip>
            <telerik:RadMultiPage runat="server" ID="MultiPage1">
                <telerik:RadPageView runat="server" ID="RadPageView1" CssClass="tab1" >
                <asp:ContentPlaceHolder ID="Holder1" runat="server" />
                </telerik:RadPageView>
                <telerik:RadPageView runat="server" ID="RadPageView2" CssClass="tab2">
                <asp:ContentPlaceHolder ID="ContentPlaceHolder2" runat="server" />
                </telerik:RadPageView>
                <telerik:RadPageView  runat="server" ID="RadPageView3" CssClass="tab3" >
                 <asp:ContentPlaceHolder ID="ContentPlaceHolder3" runat="server" />
                </telerik:RadPageView>
          </telerik:RadMultiPage></asp:contentplaceholder></div>



    .tab1
    {
        display:block !important;
    }
    .tab2
    {
        display:block !important;
    }
    .tab3
    {
        display:block !important;
    }


    Sincerely yours,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
    Answered
  8. Muhammad Saqib
    Muhammad Saqib avatar
    95 posts
    Registered:
    09 Sep 2009
    26 Nov 2009
    Link to this post
    It Worked ! Thanks
  9. lzabik
    lzabik avatar
    4 posts
    Registered:
    21 Aug 2009
    04 Jan 2010
    Link to this post
    Hi,
    I have similar problem.
    I did like you described here, but I have problems with "content areas"
    To be sure I did correct I used above code, but the problem remains. In edit mode, there is no  "content areas". There is available one "content area" when I add: SelectedIndex="0"

     <telerik:RadMultiPage runat="server" ID="MultiPage1" SelectedIndex="0"

  10. lzabik
    lzabik avatar
    4 posts
    Registered:
    21 Aug 2009
    04 Jan 2010
    Link to this post
    I solved the problem. I forgot to change PageEditorOverlay.css.
Register for webinar
10 posts, 1 answered