Logo 
Search:

Sharepoint 2010 Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint 2010       RSS Feeds

Sharepoint 2010 content editor web part

  Asked By: Guy    Date: Mar 13    Category: Sharepoint 2010    Views: 13221

What replaced the source input for the content editor web part?

Share: 

 

5 Answers Found

 
Answer #1    Answered By: Maggie Benson     Answered On: Mar 13

That's still an open question. To the best of my knowledge Microsoft
removed the ability to embed Javascript by using a Content Editor web  part
on purpose. But I haven't really seen an official comment on that omission.
But its definitely gone and I haven't seen any alternative at this point.

 
Answer #2    Answered By: Lane Trujillo     Answered On: Mar 13

It was mentioned at the SPC09. It was disabled due to the risk of cross site
scripting. It can be reenabled though. I recall it being in the properties
of the part.

 
Answer #3    Answered By: Rafael Willis     Answered On: Mar 13

You can embed javascript using a content  Editor web  part.
There are certain limitations like embedding a startup script or declaring
variables in some cases. There are workarounds as well like you have to push
your startup functions to a function stack and it gets executed.

It is not straight forward to get the source editor  popup.As you know content
editor webpart now allows inplace editing.Put your cursor in editor and wait for
couple of seconds so that Editing Ribbon appears.
Under Editing Tools -> Format Text you will find "HTML" button under "Markup"
group. Select the dropdown menu and select Edit HTML source.

 
Answer #4    Answered By: Aryan Nava     Answered On: May 14

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

Complete step by step instruction can be found at virtualizesharepoint.com/.../

 
Answer #5    Answered By: Gubata Chris     Answered On: Oct 01

If you are using in-line script, then you can try what Rafael describes, but I have found the CEWP not very good at handling robust javascript. If you have access to the server, you can save your script on a .txt file and place it in the 14 hive and then link it from the web part properties of the CEWP. I have done this many times; I usually put the files in the Styles folder under Templates -> Layouts, and then use the URL of //domain/_layouts/Styles/nameoffile.txt

I am using enterprise, so you may not have all of these options, but in the web part gallery, there is a web part that is listed as "HTML Form Web Part" and listed under Forms. I have found that this web part can handle more robust code that a CEWP has choked on.

 
Didn't find what you were looking for? Find more on Sharepoint 2010 content editor web part Or get search suggestion and latest updates.




Tagged: