How to edit source in SharePoint 2010 Content Editor Web Part (CEWP)?

If you are like me and wondering what happened to Edit Source option of Content Editor Web Part i.e. CEWP in SharePoint 2010 then don’t worry, it has moved to Ribbon.

Here is how you will edit source

  1. Click in the empty area of CEWP
  2. Under Editing Tools, click HTML and then Edit HTML Source as shown below.

Share

10 thoughts on “How to edit source in SharePoint 2010 Content Editor Web Part (CEWP)?”

  1. Thanks. But, how to do change the size of the code window that opens.

    In SP 2007, I could drag the edges and even go outside the SharePoint IE window. In SP 2010, I get a fixed box that I can scroll vertically, and that is it.

    Line wrap jumbles the code, so I copy it and edit in Notepad. Then paste it back. That seems silly.

  2. I want to use a workflow to edit the HTML source of a multiple lines of text field when an item is created in a contact list. Is this possible? If so, how?

    Thanks!

  3. Thanks for the blog.
    I got what i was searching for.
    🙂
    Suggestion:- Please try to make the pictures big so that others can see it clearly.
    Any way good work

  4. All I have is a few words of text in one of my contenet editor web parts. I do not want to use HTML. No matter what I do it messes it the spacing in the web part. Any suggestions for better way to edit other than HTML?

  5. this works with SharePoint 2010

    function ExpandCalendar() {
    firCal = SP.UI.ApplicationPages.CalendarInstanceRepository.firstInstance();
    if (firCal) {
    firCal.expandAll();
    }

    }

    _spBodyOnLoadFunctionNames.push(‘WaitForCalendarToLoad’);
    function WaitForCalendarToLoad()
    {
    if (typeof SP.UI.ApplicationPages.CalendarNotify.$4a == ‘undefined’) {
    // post SP1
    var pwold$4b = SP.UI.ApplicationPages.CalendarNotify.$4b;
    SP.UI.ApplicationPages.CalendarNotify.$4b = function () {
    pwold$4b();
    ExpandCalendar();
    }
    }
    else {
    // pre SP1
    var pwold$4a = SP.UI.ApplicationPages.CalendarNotify.$4a;
    SP.UI.ApplicationPages.CalendarNotify.$4a = function () {
    pwold$4a();
    ExpandCalendar();
    }
    }
    }

Comments are closed.

Share via
Copy link
Powered by Social Snap