Add html content inside ext:panel tags

Page 1 of 2 12 LastLast
  1. #1

    Add html content inside ext:panel tags

    What I want to do is completely basic, I want to use ext:panel (or whatever tag i want) then at some point add simple html to the page. I thought you could do this with the Content tag but this doesn't seem to work.

    <ext:AccordionLayout ID="docs" runat="server" Animate="true">
                            <Items>
                                <ext:Panel ID="docsPanel" runat="server" Border="false" AutoHeight="true"  AutoWidth="true" Layout="fit" Title="Share Documents"  Collapsed="false" Padding="10" />
                            </Items>
                            
                            <Content>
                                 <div> Want to add HTML HERE      </div>
                            </Content>
                        </ext:AccordionLayout>
                    </Items>
                </ext:Panel>
    Last edited by geoffrey.mcgill; Jan 02, 2011 at 2:53 PM. Reason: please use [CODE] tags
  2. #2
    Hi,

    I'm not sure why the <Content> tag is exposed on the Layout components. It should (will) be removed.

    Just move your raw html into the <Content> region of a Panel type component, such as <ext:Panel>.

    Hope this helps.
    Geoffrey McGill
    Founder
  3. #3
    Quote Originally Posted by geoffrey.mcgill View Post
    Hi,

    I'm not sure why the <Content> tag is exposed on the Layout components. It should (will) be removed.

    Just move your raw html into the <Content> region of a Panel type component, such as <ext:Panel>.

    Hope this helps.
    OK so now I have this but still doesn't work. Please show a code snippet if you can. I appreciate the quick response, thanks.

    <Items>
                                <ext:Panel ID="docsPanel" runat="server" Border="false" AutoHeight="true"  AutoWidth="true" Layout="fit" Title="Share Documents"  Collapsed="false" Padding="10" >
                                
                                                             <div>RAW HTML HERE                             </div>
                                </ext:Panel>
                            </Items>
    Last edited by geoffrey.mcgill; Jan 02, 2011 at 7:23 PM. Reason: please use [CODE] tags
  4. #4
    Quote Originally Posted by kirkhas View Post
    OK so now I have this but still doesn't work. Please show a code snippet if you can. I appreciate the quick response, thanks.

    <Items>
                                <ext:Panel ID="docsPanel" runat="server" Border="false" AutoHeight="true"  AutoWidth="true" Layout="fit" Title="Share Documents"  Collapsed="false" Padding="10" >
                                
                                                             <div>RAW HTML HERE                             </div>
                                </ext:Panel>
                            </Items>

    Your code sample is fine, but you are missing the inner <Content> tags. The html should be added inside the <Content> tags.
    Geoffrey McGill
    Founder
  5. #5

    html inside content tag

    Quote Originally Posted by geoffrey.mcgill View Post
    Your code sample is fine, but you are missing the inner <Content> tags. The html should be added inside the <Content> tags.
    OK so I got html to show up by putting it in the content tag BUT.. I can't get server tags to work or javascript. How can I do this in the content tag.
  6. #6
    Quote Originally Posted by kirkhas View Post
    OK so I got html to show up by putting it in the content tag BUT.. I can't get server tags to work or javascript. How can I do this in the content tag.
    Please post a code sample demonstrating the scenario.
    Geoffrey McGill
    Founder
  7. #7

    server tag nested inside ext:panel

    Quote Originally Posted by geoffrey.mcgill View Post
    Please post a code sample demonstrating the scenario.
    <ext:Panel ID="docsPanel" runat="server" Border="false" AutoHeight="true"  AutoWidth="true" Layout="fit" Title="Share Documents"  Collapsed="false" Padding="10" >
                                  <Content>
                                     <div>Upload Group Documents! Share docs in a central place.<br />
                                            <div id="docwarning"></div>
                                            <%if ((Session["GroupMembership"] as GroopityApp.Models.GroupMembership).IsAdmin)
                                              {%> 
                                                <form action="/Group/UploadFile/" enctype="multipart/form-data" method="post" id="fileUploadForm<%=Html.Encode(grp.group_id) %>" style="display:inline;">
                                
                                                    <input type="file" name="newFile" />
                                                    <input type="button" id="uploadButton" onclick="docUpload('fileUploadForm<%=Html.Encode(grp.group_id) %>')" value="Upload" />
                                                 </form>
                                               <%}%>
                                                <br />
                                               <div id="docTable" style="float:left; padding:5px 5px 5px 0px;">                       
                                               </div>
                                       </div>
                                    </Content>
                                </ext:Panel>
    Any content other than plain html seems to cause the page to not render. this is getting painful
    Last edited by kirkhas; Jan 03, 2011 at 2:51 AM.
  8. #8
    Hi,

    Please wrap your code sample in [CODE] tags.

    Review of the following page will help avoid future delay in getting a response, see

    http://forums.ext.net/showthread.php...ing-New-Topics
    Geoffrey McGill
    Founder
  9. #9
    Well, your code sample appears to work properly for me (after I fix the exceptions that are thrown).

    The onclick handler is called properly.

    You might also be running into problems with having nested <form> tags.
    Geoffrey McGill
    Founder
  10. #10

    mixed form panel

    I could have sworn i saw in some example a form panel mixed with html content. But i don't remember the tag name that was used.

    I think this was it.

    https://examples1.ext.net/#/Panel/Basic/FormGroup/
    Last edited by craig2005; Jan 03, 2011 at 4:04 PM.
Page 1 of 2 12 LastLast

Similar Threads

  1. Html content inside panel
    By Birgit in forum 2.x Help
    Replies: 1
    Last Post: Apr 02, 2012, 2:34 PM
  2. html tags inside container
    By [WP]joju in forum 1.x Help
    Replies: 4
    Last Post: Nov 20, 2009, 2:39 AM
  3. Print content inside a panel
    By Nagaraj K Hebbar in forum 1.x Help
    Replies: 0
    Last Post: May 19, 2009, 2:14 AM
  4. [CLOSED] panel content as html
    By alexp in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: May 01, 2009, 6:53 AM
  5. html tags in textfields
    By [WP]joju in forum 1.x Help
    Replies: 0
    Last Post: Apr 16, 2009, 9:46 AM

Posting Permissions