locked
In sharepoint online script editor and content editor webparts are not there in modern webpage. how to use those webparts? RRS feed

  • Question

  • I want to customize my sharepoint online modern page through some code.........like changing font style,hiding,....etc.

    Are is there any alternate option to write some code? similar to script editor and content editor

    Kind regards,

    Anil kumar.

    Friday, July 17, 2020 10:23 AM

All replies

  • You will have to enable the custom scripts on your SharePoint Online Site/tenant.



    For a particular site collection, use:

    Connect-SPOService -Url https://tenant-admin.sharepoint.com

    Set-SPOSite -Identity https://tenant.sharepoint.com/sites/contoso -DenyAddAndCustomizePages 0



    To enable it for complete tenant, go to SharePoint Online Admin center in classic settings page.

    In Custom scripts section, click "Allow users to run custom script on personal sites" and  "Allow users to run custom script on self-service created sites"

    Please be aware the Microsoft is working towards disabling the scripts completely from SharePoint Online. The best way to customize would be using Spfx solutions. 

    Friday, July 17, 2020 5:58 PM
  • Hi Anil kumar,

    The Script Editor web part and Content Editor Web Part are not available in SharePoint for Microsoft 365 modern pages.

    For the need of adding and formatting texts, you can use the OOTB Markdown web part or Text web part. For advanced customization on modern pages, consider using the SharePoint Framework (SPFx) to build and deploy client-side web parts for modern pages in SharePoint Online.

    Here is your reference:

    Where are the Content editor and Script editor web parts in SharePoint?

    https://support.microsoft.com/en-ie/office/where-are-the-content-editor-and-script-editor-web-parts-in-sharepoint-ed6cc9ce-8b2a-480c-a655-1b9d7615cdbd

    ---

    This “SharePoint 2010 - General Discussions and Questions” Forum will be migrating to a new home on Microsoft Q&A, please refer to this sticky post for more details.

    Best regards,

    Chelsea Wu


    "SharePoint" forums will be migrating to a new home on Microsoft Q&A !
    We invite you to post new questions in the "SharePoint" forums' new home on Microsoft Q&A !

    Monday, July 20, 2020 6:27 AM
  • Hi,

    This forum will be locked down, if you need further assistance with this issue, you can continue to post in here before 8/10/2020. It is recommended to create a new question on Microsoft Q&A, we will continue to support you on the new home.

    Thank you for your understanding.

    Best regards,

    Chelsea Wu


    "SharePoint" forums will be migrating to a new home on Microsoft Q&A !
    We invite you to post new questions in the "SharePoint" forums' new home on Microsoft Q&A !

    Tuesday, August 4, 2020 2:29 AM