Error in creating new/edit Webpart layout

Ahmad Shah Barhanuddin asked on October 27, 2016 11:12

Hi ,

Getting error as below. Please help..

Description: Message: A potentially dangerous Request.Form value was detected from the client (m$c$PreviewHierarchy1$mainLayout$mainPane$layoutElem$paneContent$General$EditForm$etaCode$txtCode="" %><asp:Literal ID="ltl...").

Exception type: System.Web.HttpRequestValidationException Stack Trace: at System.Web.HttpRequest.ValidateString(String value, String collectionKey, RequestValidationSource requestCollection) at System.Web.HttpRequest.ValidateHttpValueCollection(HttpValueCollection collection, RequestValidationSource requestCollection) at System.Web.HttpRequest.get_Form() at System.Web.UI.Page.DeterminePostBackMode() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) at System.Web.UI.Page.ProcessRequest() at System.Web.UI.Page.ProcessRequest(HttpContext context) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

Event URL: /CMSModules/PortalEngine/UI/WebParts/Development/WebPart_Edit_Layout_New.aspx?sitemanager=1&webPartID=175&parentobjectid=175&tabslayout=horizontal&tabselemid=m_c_plc_lt_ctl00_HorizontalTabs_l_t_tabsElem

Recent Answers

Roman Hutnyk answered on October 27, 2016 11:27

It would be nice if you provide more details on error, e.g. what your doing, when error happens, etc.

Looks like you're trying to submit a form, which contains some html tags, which causes XSS error.

1 votesVote for this answer Mark as a Correct answer

Ahmad Shah Barhanuddin answered on October 27, 2016 12:28

Hi Roman,

This is what i do, I need to create a new layout for this web part. After that, when i try to save this new layout, i got above error. Also I try to edit existing layout, it cause the same problem.

0 votesVote for this answer Mark as a Correct answer

Manmath Kulkarni answered on November 4, 2016 17:13

Hi Roman,

I am using Kentico 9. I have created web part with Image and Text fields in it. I am using this web part in newly created page. Though I am able to add this web part to page, but I am not able to edit layout of this web part. I have tried using default layout and also have tried to create new layout and edit it.

1. Create web part 'Test' with Image and text in it.
2. Create page -> in Design tab add Web Part 'Test' in page.
3. Configure and edit layout of Web part. Use default or Create new layout both fails.

Getting following error from ScriptResource.axd file.

SCRIPT5022: Sys.InvalidOperationException: Could not find UpdatePanel with ID 'm_c_ucHierarchy_mainLayout_mainPane_layoutElem_paneToolbar_pnlUpdate'. If it is being updated dynamically then it must be inside another UpdatePanel.

I am trying to add HTML tags in layout.

Also it would be helpful if you can provide sample code to add tags in layout.
Can you please provide solution or workaround for this error.

Best regards,

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.