Alireza A
Alireza A

Reputation: 33

Kentico custom table data editing issue

Custom table's data hangs on the loading screen after saving any changes. This is happening on some of tables and it seems that the majority of records are saved, however I have noticed a couple that didn't save within some custom table until reapplying the change!

I was wondering what can cause the issue.

Upvotes: 1

Views: 308

Answers (2)

jurajo
jurajo

Reputation: 995

This was just brought to my attention, not sure how I missed it before. So, I will post my answer just for the future reference :-) I guess there is some SLL offloading going on before the actual IIS where Kentico is running. In this case, SSL Accelerator must be implemented. The link goes to Xperience 13 version but the same idea applies for older versions. Just use the version selector in the top bar - there could be some API differences.

And the same applies e.g. when uploading media files - the browser console will show mixed content warning. This is for security reasons. Browser sees the HTTPS but behind the offloader there is HTTP communication and the GetAbsoluteURL method takes the protocol from the request. Thus, mixed content. Using the ssl accelerator will tell Kentico to use HTTPS internally.

Upvotes: 0

Alireza A
Alireza A

Reputation: 33

I have found the issue using browser's developer tools.

Issue

Clicking save button was creating Mixed Content: The page at 'https://address' was loaded over HTTPS, but requested an insecure form action 'http://address'. This request has been blocked; the content must be served over HTTPS. JS error on the browser and browser was blocking the content. However, the form action was not pointing to absolute URL address.

Solution

As the server SSL config was fine, therefore, there was not any other way than changing core CustomTableForm.ascx.cs Kentico file. Although it is not recommended. The problem solved by developing RedirectUrlAfterSave property of customTableFormobject to make sure it will redirect correct protocol instead of Absolute URL

Hope it will help you guys.

Upvotes: 1

Related Questions