質問

I have a WebControl on my site that has an asp:RadioButtonList on it.

I have the RepeatLayout property set to 'Table'.

When I view the site normally, it renders correctly (as a table).

We have then setup a CDN, that the entire site passes through, but only images, JS and CSS files are retrieved from the CDN, and the rest of the site passes through and hits our servers (so aspx requests are still coming off a server that I have direct access to).

While in testing, I have setup my hosts file to point to the CDN address.

Everything else seems fine, yet the RadioButtonList is rendering as input and label tags, separated by <br />'s. This is how it should render if I had RepeatLayout set to "Flow".

I can even edit the text in the ListItems in the control, and see that they update, so it's definitely hitting my server.

Does anyone have an idea why my tests using the CDN are returning the incorrect markup, only for RadioButtonLists?

役に立ちましたか?

解決

We've finally found the issue.

Akaimai was sending it's own user agent, Akamai-Edge, through to our servers in the request for the page.

In doing so, our servers were returning different markup based on the user agent. (Our site runs off the CMS Sitecore, which has user-agent dependent markup.)

We managed to fix this by changing the Akamai config so that the normal user agent from the website visitor is passed through to our servers in the request, instead of the Akamai one.

I suspect that this is also a bug in Sitecore (not returning the default markup for an unknown user-agent).

他のヒント

Have you checked the HTML in Firebug or Chrome Developer Tools? Inspect the generated RadioButtonList HTML and check that the CSS that is being applied is coming from the correct CSS file. It could the CSS is from some (non CDN) source that is overriding the table layout of the control.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top