Widgets Configuration issues

Hosam Abdeltawab asked on August 17, 2020 18:16

I am in the process of adding widgets to my site using kentico 12. I followed the example in https://docs.kentico.com/k12/developing-websites/page-builder-development/developing-widgets-in-mvc/example-developing-a-widget-in-mvc

Whenever I try to add the widget to Kentico's UI it gives an error and nothing is shown in the error log. I added another widget without a model or properties, just a controller that returns a partial view and it gets added. Here is what I added for the example widget that is on Kentico's docs, I added all the controllers, models, properties of both the widget and the inline editor in the appropriate folders. I added the assembly to register the widget.

I am getting a 400 error in the console.log for GetWidgetDefaultProperties.

What might be causing the widgets not to get added? Is there some sort of configuration that needs to be set?

Correct Answer

Brenden Kehren answered on August 17, 2020 20:41

Then make sure your widget is properly configured with properties and you're retrieving them properly.

0 votesVote for this answer Unmark Correct answer

Recent Answers


Brenden Kehren answered on August 17, 2020 20:27

On the page you get an error on, right click in the content area and inspect the page. In the console log, look for an error with a URL starting with /cmsctx/ and click on it. This should bring you to another page with more details. If not, you'll have to inspect your code more as the Kentico UI doesn't provide a lot of help with this. Possibly add some try{}catch{} blocks and log events to the event log in your code.

0 votesVote for this answer Mark as a Correct answer

Hosam Abdeltawab answered on August 17, 2020 20:33

I am getting a 400 error in the console.log for GetWidgetDefaultPropertie

0 votesVote for this answer Mark as a Correct answer

Hosam Abdeltawab answered on August 17, 2020 21:06 (last edited on August 17, 2020 21:36)

0 votesVote for this answer Mark as a Correct answer

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