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

Forums / General Discussions / Sitefinity -
instead of

when pressing enter in the radeditor (WYSIWYG)

Sitefinity - <br /> instead of <p></p> when pressing enter in the radeditor (WYSIWYG)

3 posts, 0 answered
  1. ansar foolchand
    ansar foolchand avatar
    13 posts
    Registered:
    17 Feb 2010
    04 Aug 2010
    Link to this post
    Hi,

    I am actually using Sitefinity version 3.7.2096 and I have a question about the radeditor (WYSIWYG):
    It is possible to force the editor to use a <br /> instead of a <p></p> when the user presses enter in the editor when adding a generic content to a page.

    Thanking you in anticipation.
    Ansar
  2. Radoslav Georgiev
    Radoslav Georgiev avatar
    3370 posts
    Registered:
    01 Feb 2016
    04 Aug 2010
    Link to this post
    Hello ansar foolchand,

    Thank you for using our services.

    The RadEditor has a property NewLineBr which sets it to use br instead of p tags. In order to set the editor you will need to work with the external templates for Sitefinity. You need to download the external templates archive and map those templates which use the RadEditor. Then you just need to set the property:
    <telerik:RadEditor
        runat="server"
        ID="textEditor"
        ContentAreaCssFile="~/Sitefinity/Admin/Themes/Default/AjaxControlsSkins/Sitefinity/EditorContentArea.css"
        ToolsFile="~/Sitefinity/Admin/ControlTemplates/EditorToolsFile.xml"   
        Skin="WebBlue"   
        NewLineBr="True"
        Height="360px"
        Width="98%"  ContentFilters="EncodeScripts,FixUlBoldItalic,FixEnclosingP,IECleanAnchors,MozEmStrong,ConvertFontToSpan,ConvertToXhtml,IndentHTMLContent">
        <ImageManager ViewPaths="~/Images" UploadPaths="~/Images" DeletePaths="~/Images" />
        <MediaManager ViewPaths="~/Files" UploadPaths="~/Files" DeletePaths="~/Files" />
        <FlashManager ViewPaths="~/Files" UploadPaths="~/Files" DeletePaths="~/Files" />
        <DocumentManager ViewPaths="~/Files" UploadPaths="~/Files" DeletePaths="~/Files" />
        <CssFiles>
            <telerik:EditorCssFile Value="~/Sitefinity/Admin/Themes/Default/AjaxControlsSkins/Sitefinity/EditorCssFile.css" />
        </CssFiles>
    </telerik:RadEditor>

    More information on how to map control templates can be found here: How to map a view to an external template, in Sitefinity 3.6 or later?

    Greetings,
    Radoslav Georgiev
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. Gavin
    Gavin avatar
    2 posts
    Registered:
    19 Mar 2013
Register for webinar
3 posts, 0 answered