問題
- Liferay DXPサイトのホームページについて、 のURL検査 - の「ライブテスト」 を のGoogle Search Console で行った後、のURL検査を行いました。視覚的なエラーは「スクリーンショット」プレビュータブに表示され、「ページリソース」では「JavaScriptコンソールメッセージ」エラーと同様に「詳細情報」タブに表示されます。
その一部をリストアップして見せること。
/combo?browserId=other&minifierType=js&languageId=en_US&b=7010&t=1585307742000&/o/product-navigation-control-menu-dxp-theme-contributor/product_navigation_control_menu.js couldn't be loaded
/o/classic-theme/css/aui.css?browserId=other&themeId=classic_WAR_classictheme&minifierType=css&languageId=en_US&b=7010&t=1585307796999 couldn't be loaded
/o/frontend-js-web/everything.jsp?browserId=other&themeId=classic_WAR_classictheme&colorSchemeId=01&minifierType=js&minifierBundleId=javascript.everything.files&languageId=en_US&b=7010&t=1585307748762 couldn't be loaded
Uncaught ReferenceError: AUI is not defined
Uncaught TypeError: Cannot read property 'run' of undefined
環境への配慮
- ライフレイDXP 7.0
決議
- Liferayサイトに移動 > 公開ページ > ロボットの設定 > 高度な設定 > ロボットを設定し、以下のように
robots.txtを設定します。
User-Agent: *
ここで
Disallow:
User-agent: Googlebot
Disallow:
User-agent: AdsBot-Google
Disallow:
User-agent: Googlebot-Image
Disallow:
Sitemap: https://${HOMEPAGE}/sitemap.xml${HOMEPAGE}は、例えば、あなたのサイトのホームページです。 https://www.liferay.com
です。
- 変更後も問題が残る場合。
1) サーバーを停止し、以下のフォルダの内容をクリアします。
- Liferay/osgi/state
- Liferay/work
(Tomcat:)
- Tomcat/work
- Tomcat/temp
2)サーバーを再起動し、Googleツールにサイトを再投稿する