Header & Footer On rad editor

8 posts, 0 answers
  1. R
    R avatar
    3 posts
    Member since:
    Jan 2007

    Posted 23 Jul 2008 Link to this post

    I am using RadEditor For ASP.Net AJAX

    I want to give PageBreaks and Header, Footer Informations on each page.
    Is any feature provided by RadEditor?? or how can I implement these features??

    Regards,
    Ramesh R.
  2. Rumen
    Admin
    Rumen avatar
    12846 posts

    Posted 24 Jul 2008 Link to this post

    Hi Ramesh,

    If I understand your scenario correctly, you need to specify header and footer in the content area of RadEditor. Unfortunately, the HTML specification does not offer tags for header / footer information and you should paste manually or via a custom button HTML content similar to this one below:

    sample content1


    footer information
    1. content - description

    In addition, you cannot automatically divide the content in the editor to different pages. Searching for <p> breaks gives the most natural break, but those breaks might occur on an undesired location. That is why the only reliable way to break the page is by manual inserting a page break style. The style='page-break-before: always' will tell the printer that this is the end of the current page and will print the subsequent content on a new page. You can found more information the this KB article: Implementing a page-break button in RadEditor 5.x - 7.x and RadEditor "Prometheus".

    If you are able to find any other DHTML editor (not ActiveX or Java which requires installation on the client) that offers the requested features, please send us a link to its site or demos. This will help us a lot to implement these features in our editor.


    Best regards,
    Rumen
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Ricardo
    Ricardo avatar
    2 posts
    Member since:
    Dec 2014

    Posted 29 Jan 2015 Link to this post

    Greetings, 
    I saw that this post is from 2008, and my answer still the same.
    I need to Load some docxfiles on my radeditor, and insert a Header and a Footer depending on the enterprised logged in.
    Which is the method or funcionality that allow me to do that?

    Best regards, 
    Ricardo Ferreira
  5. Cristiano
    Cristiano avatar
    13 posts
    Member since:
    Feb 2012

    Posted 29 Jan 2015 Link to this post

    Greetings, 
    I saw that this post is from 2008, and my answer still the same.
    I need to Load some docxfiles on my radeditor, and insert a Header and a Footer depending on the enterprise logged in.
    Which is the method or funcionality that allow me to do that?

    Regards.

  6. Ianko
    Admin
    Ianko avatar
    1535 posts

    Posted 03 Feb 2015 Link to this post

    Hi Cristiano and Ricardo,

    Could you please specify how header and footers should apply in the editable HTML document? Note that in HTML documents (moreover editable) the concept of headers and footers is quite different from the one in the rich text documents. Due to that, I can only make guesses what your exact expectations are.

    Basically, you can predefine HTML content via the Content property and add markup that would serve as header and footer.

    Regards,
    Ianko
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  7. Cristiano
    Cristiano avatar
    13 posts
    Member since:
    Feb 2012

    Posted 03 Feb 2015 in reply to Ianko Link to this post

    Hi Ianko.
    For each company registered in our website, we have different headers to apply soon as they open the RadEditor, and we have to inject this header and footer programmatically.
    The question is basically, if there is any property that can pass the text or html code directly to the position of the document header or footer.
    If not possible, we will have to put, for example, the footer at the end of all text and calculate the size of an A4 sheet to get through the footer at the very end of the page.

    Another question is whether it is possible to define the content as a A4 or letter  sheet  easily  or how can I make it with CSS.

    Best Regards,
    Ricardo Ferreira
  8. Marin Bratanov
    Admin
    Marin Bratanov avatar
    3595 posts

    Posted 05 Feb 2015 Link to this post

    Hello Ricardo,

    There is no concept of headers, footers and pages in HTML. Thus, there is none in RadEditor. The suggestions Rumen provided in his first post in this thread are still relevant and apply.

    If Ianko's suggestion of directly modifying the HTML does not work for you, and if it applies to your case, you can consider adding headers and footers programmatically to content you export from the editor to DOCX: http://www.telerik.com/help/aspnet-ajax/editor-export-to-docx-and-rtf.html#modifying-exported-content. If you choose this approach I advise upgrading to the latest version (Q1 2015 BETA at the moment).

    As for applying CSS to the content - media queries (e.g., for printed media) are not something RadEditor can create for you and they also cannot insert content, they can only style existing content so it is printer-friendly.

    On calculating things with JavaScript - again, since there is no concept of paging in HTML, RadEditor does not offer such a facility. You can obtain its content via the get_html(true) method and modify it as you desire, then use set_html(theNewContent) to put it back in the editor.

    Regards,

    Marin Bratanov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  9. TheXplorer
    TheXplorer avatar
    6 posts
    Member since:
    Jul 2009

    Posted 28 Apr 2015 Link to this post

    I want to achieve footer like the file which i attached. 

    i have very limited option like below. 

    reMemoMsg.ExportSettings.Pdf.PageFooter.LeftCell.Text = "<img  border=\"0\" src=\"images/signatures/memowf/OfficeUse01.jpg\" />";
    reMemoMsg.ExportSettings.Pdf.PageFooter.MiddleCell.Text = "<img border=\"0\" src=\"images/signatures/memowf/OfficeUse02.jpg\" />";
    reMemoMsg.ExportSettings.Pdf.PageFooter.RightCell.Text = "<img border=\"0\" src=\"images/signatures/memowf/OfficeUse03.jpg\" />";

    please advise how to achive the same while exporting to PDF

Back to Top
UI for ASP.NET Ajax is Ready for VS 2017