HTML editor for SharePoint default content

4 posts, 0 answers
  1. Mai
    Mai avatar
    2 posts
    Member since:
    Jan 2009

    Posted 19 May 2015 Link to this post


    I using Telerik for SharePoint on a page layout I am using the tag below

    <telerik:RadHtmlField id="EnglishContent" FieldName="English Content" runat="server"> </telerik:RadHtmlField>

    My customer requires to have a default text value inside this editor every time the user creates new page from the page layout. When I am trying to use rhe <content> tag I got an error that the tag content is not recognized as a Rad HTML Field tag.
  2. Ianko
    Admin
    Ianko avatar
    1535 posts

    Posted 22 May 2015 Link to this post

    Hello Mai,

    You cannot use RadEditor properties inside the RadHtmlField Web Part. You should firstly point the contig file to be used (http://www.telerik.com/help/aspnet-ajax/moss-sp2010-setting-config-tools-files-in-wcm.html), and then you can modify the controls properties via the ConfigFile (http://www.telerik.com/help/aspnet-ajax/moss-sp2010-set-properties-via-config-file.html).

    I should warn you that the Content property will override the text each time the page is edited. Therefore, I can suggest using the EmptyMessage property to add initial text:
    <property name="EmptyMessage">add some text</property>


    Regards,
    Ianko
    Telerik
    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 Feedback Portal and vote to affect the priority of the items
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Mai
    Mai avatar
    2 posts
    Member since:
    Jan 2009

    Posted 27 May 2015 in reply to Ianko Link to this post

    This Empty message property is not working for me . Actually I have two rad editor controls, one for Arabic content and one for English content and even if empty message working both Arabic & English content will be the same.

    Any idea about how to have an English default Content and Arabic default Content 

     

    Regards,

    Mai

  5. Ianko
    Admin
    Ianko avatar
    1535 posts

    Posted 28 May 2015 Link to this post

    Hi Mai,

    The answer to this question entirely depends on how the SharePoint site is localized. If there are different sites for each language, then you can go with the approach to have different config files for the different sites—http://www.telerik.com/help/aspnet-ajax/moss-sp2010-different-configuration-files-for-different-webs.html.

    If the localization is handled with different approach, you can handle the OnClientLoad event (http://www.telerik.com/help/aspnet-ajax/moss-sp2010-using_radeditors_client-side_events_in_sharepoint.html), and use the editor's client-side set_emptyMessage() method to change the message, with a localization property or plain string value.

    Regards,
    Ianko
    Telerik
    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 Feedback Portal and vote to affect the priority of the items
Back to Top