Repeating content in master pages

Discussion in 'ASP .Net Web Controls' started by Vrlvrox, Nov 27, 2008.

  1. Vrlvrox

    Vrlvrox Guest


    I'm just starting with master pages and content placeholders and I can't
    seem to find a way to have 'repeating content'.
    Is something like this even posible?
    Here's an example of what I mean (in pseudo tags):

    <asp:repeating content placeholder id="rcp">
    <tr><td><asp:ContentPlaceHolder id="col1"
    /></td><td><asp:ContentPlaceHolder id="col2" /></td></tr>
    </asp:repeating content placeholder>

    page with content substitution:
    <asp:repeating content placeholder="rcp">
    <asp:Content ContentPlaceHolderID="col1">Row 1 Col1</asp:Content>
    <asp:Content ContentPlaceHolderID="col2">Row 1 Col2</asp:Content>
    </asp:repeating content>
    <asp:repeating content placeholder="rcp">
    <asp:Content ContentPlaceHolderID="col1">Row 2 Col1</asp:Content>
    <asp:Content ContentPlaceHolderID="col2">Row 2 Col2</asp:Content>
    </asp:repeating content>

    final result:
    col1 | col2
    Vrlvrox, Nov 27, 2008
    1. Advertisements

  2. I don't believe it is, the best way to achieve that would probably be to use
    a repeater in the content page.
    Nathan Sokalski, Nov 27, 2008
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.