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

Forums / Developing with Sitefinity / RadEditor and Default Text

RadEditor and Default Text

4 posts, 0 answered
  1. Craig Taylor
    Craig Taylor avatar
    10 posts
    Registered:
    22 Apr 2010
    03 Feb 2011
    Link to this post
    I've created a custom module.

    I have a RadEditor within the edit page. When this page is displayed the RadEditor has the text "Type your content here...". I don't want this text to show up at all that is I want the RadEditor to be blank.

    I've tried adding the <Content></Content> attribute in the ascx page and also I've tried adding 

    <script runat="server" language="C#">
        protected void Page_Load
            (
            object sender,
            EventArgs e)
        {
            if(!Page.IsPostBack)   
                    contentEditor.Content = "";
        }
          
        // clear the text when you hit save button
        protected void saveButton1_Click(object sender, EventArgs e)
        {
            contentEditor.Content = contentEditor.Content.Replace("Type your content here...", "");
        }
    </script>

    Neither approach works.

    Any help would be much appreciated.

    Regards

    Craig
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    03 Feb 2011
    Link to this post
    Hi Craig,

    Could you tell me which view you are trying to modify. The text you see is shown when you create a new content item. Most probably you are not adding the code on the right place.

    Best wishes,
    Ivan Dimitrov
    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. Yash
    Yash avatar
    1 posts
    Registered:
    27 Jan 2012
    27 Jan 2012
    Link to this post
    Hi Ivan Dimitrov,
    I have the same problem. I want to change the default text but I am unable to do so (because I don't know where to start).
    I am new to Sitefinity and any help or pointers would be highly appreciated.

    Thanks,

    Yash
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    25 Nov 2016
    30 Jan 2012
    Link to this post
    Hello,

    First you need to map the external template for the view you want to modify, then you need to change the template as shown above to get the initial text changed.

    Greetings,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Register for webinar
4 posts, 0 answered