我在2台由负载均衡器管理的IIS服务器上安装并配置了Wordpress。
当我上传一个新的主题"essentials“时,上传进行得很顺利。
当我尝试预览我的essentials主题(外观->主题->,我在essentials主题上选择“实时预览”)时,我得到错误500。网络请求为:
表单数据:
_method: GET
wp_customize: on
customize_theme: essentials
nonce: 246d76c7f3
customize_changeset_uuid: 7a0a2113-ff98-40ba-ae4a-f12fd96c92c7
customize_autosaved: on
customized: {"old_sidebars_widgets_data":{"wp_inactive_widgets":[],"sidebar-1":["recent-posts-2"],"sidebar-2":["archives-2","categories-2","meta-2"]},"nav_menu_locations[menu-1]":2}
customize_messenger_channel: preview-0例如,当我单击其他有效主题(名为twentynineteen)的预览时,我会看到以下内容
表单数据:
_method: GET
wp_customize: on
customize_theme: twentynineteen
nonce: 4cbd22eb68
customize_changeset_uuid: e471b84f-c500-4a81-8c0b-d8f49ca62410
customize_autosaved: on
customized: {"old_sidebars_widgets_data":{"wp_inactive_widgets":[],"sidebar-1":["recent-posts-2"],"sidebar-2":["archives-2","categories-2","meta-2"]},"nav_menu_locations[menu-1]":2}
customize_messenger_channel: preview-1我签出了,我的essentials主题存在于两台服务器上的\wp-content\themes文件夹中。
发布于 2021-11-15 10:47:04
我设法解决了这个问题。第二台服务器上的web.config神秘地遗漏了这条规则
<rule name="xxxx http to https" stopProcessing="true">
<match url="(.*)" ignoreCase="true" />
<conditions logicalGrouping="MatchAll">
<add input="{HTTP_HOST}" pattern="^(www.)?xxxx\.com$" />
<add input="{HTTPS}" pattern="off" />
<add input="{URL}" pattern="(.*)" />
</conditions>
<action type="Redirect" url="https://xxxx/{R:1}" redirectType="Permanent" />
</rule>它以前就在那里。可能是升级或者什么东西把它删除了。
xxxx代表我的域名
https://stackoverflow.com/questions/69972764
复制相似问题