PageBuilder jQuery issues

Stephen Herz asked on December 14, 2021 15:34

Developing on Kentico 13.0.47

I've created a page builder page that has a single drop-zone. I can add widgets to the page, and they render correctly. But now I'm trying to add a widget that has a 'page selector' property. The widget renders, but when I try to select a Page using the "configure widget" pane, next to the label (which is rendered correctly) I see the word "undefined". Here is my property:

[EditingComponent(PageSelector.IDENTIFIER, Label = "Selected Service Blocks", Order = 2)]
[EditingComponentProperty(nameof(PageSelectorProperties.RootPath), "/Reused-Content/Service-Blocks")]
[EditingComponentProperty(nameof(PageSelectorProperties.MaxPagesLimit), 6)]
public IEnumerable<PageSelectorItem> ServiceBlocks { get; set; } = Enumerable.Empty<PageSelectorItem>();

Text properties are working, but not Page Selector or Object Selector. One thing I notice, I see a few JavaScript errors on the page. I see 404 errors for the following:

https://localhost:44346/_content/Kentico.Content.Web.Rcl/Scripts/jquery-3.5.1 https://localhost:44346/_content/Kentico.Content.Web.Rcl/Scripts/jquery.unobtrusive-ajax.js.js https://localhost:44346/Kentico/Scripts/shim.min.js.map https://localhost:44346/PageBuilder/Public/Widgets/swiper-bundle.js.map

I believe these are the scripts loaded by using @Html.Kentico().PageBuilderScripts() in the view see I don't think I have control over the URL. Any ideas on why my selectors are not working?

Correct Answer

Stephen Herz answered on December 15, 2021 16:35

David, It is upgraded to version 13.0.47 and uses .NET Core

I experienced the problem while running on my local environment which uses 'localhost' running on IIS express to display the site. However, when I deploy this to an actual IIS web server, all is working properly, and I see no 404 errors. Something on my local Visual Studio environment is preventing the scripts from loading. I'm not sure I'll spend that much time debugging my local environment since it is running on the server.

0 votesVote for this answer Unmark Correct answer

Recent Answers


David te Kloese answered on December 15, 2021 10:44

Hi,

is this an upgraded instance? Do you have the issue on other installations too?

0 votesVote for this answer Mark as a Correct answer

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