Multisite
-
Hello,
I have difficulties to run the plugin successfully on a multisite. If I check it with Lighthouse, the error is:
Web app manifest or service worker do not meet the installability requirements
Failure reason
Page does not work offlineAnd I can’t install the app in Chrome. I have running the plugin on a single site also, there the problem does not exist. The settings are in principle the same.
-
Can you please share the URL of your website? So that we will look into it and get back to you shortly.
Can you please share few screengrabs of your dashboard PWAforWP set-up settings? So that we will look at it and get back to you shortly.
I set up a new Test Multisite with Subdirectory and all defaults. The only plugin, I installed is PWA. I activated it for the main site with its default settings. Chromes developer console logs following error:
The script resource is behind a redirect, which is disallowed.
I changed the first line from pwa-register-sw-1.js:
false:var swsource = "https://my-domain.de/e?pwa_for_wp_script=1&sw=pwa-sw-1-js";
valid:var swsource = "https://my-domain.de/e/?pwa_for_wp_script=1&sw=pwa-sw-1-js";Testing the webpage with Chrome Lighthouse, the same as above:
Web app manifest or service worker do not meet the installability requirements
reason
Service worker is the technology that enables your app to use many Progressive Web App features, such as offline, add to homescreen, and push notifications. With proper service worker and manifest implementations, browsers can proactively prompt users to add your app to their homescreen, which can lead to higher engagement. Learn more.Failure reason
Page does not work offlineGoogleing this, I find out, this may be a Chrome Lighthouse feature. But why the problem doesn’t exist on a single site?
I Have the same problem too, exactly the same.
Can you please let me know, Have you installed PWAforWP plugin at your end? Please check it once and let me know back.
faelmarcondeli: As per forum guidelines, Please create a new topic.
Can you please let me know, Have you installed PWAforWP plugin at your end? Please check it once and let me know back.
Of course. https://phw-web.de/e/ is the main site of the test network installation, https://phw-web.de/e/1/ is a sub website. All settings are the defaults.
Thanks for the confirmation. We are checking your issue and we will get back to you shortly.
Can you please uncheck “PWA alternative method” to serve service workers in the setting Advance section?
“PWA alternative method” was and is unchecked on both sites. Should I check it?
I see your scan in the logs, and I don’t see any other status code as 200.Reference screengrab: https://prnt.sc/1ec7xoh
As we can check for service worker there 2 calls. one RESPONSE with 301 and the other one is 200.That’s the cause of the issue, the service worker is registered but it’s the second time.
This issue I had in https://ww.wp.xz.cn/support/topic/multisite-624/#post-14648330 too. Thats why I changed pwa-register-sw-1.js as described there.
Today I updated to WordPress 5.8 and to PWA 1.7.35 and it is the same as before:
– the slash is missing on the main page in pwa-register-sw-1.js.
– I corrected this.
– Lighthouse reports the same as above.
– On the subsite the problem with the slash does not exist, but Lighthouse reports the error too.Alright, We will check the issue and get back to you.
Thank you for the new version. It works on the main site, but for the subsite doesn’t. It works if I write the following lines in .htaccess for the site with blogid 2:
RewriteRule .*/pwa-register-sw-2.js /pwa-register-sw-2.js [L] RewriteRule .*/pwa-sw-2.js /pwa-sw-2.js [L] RewriteRule .*/pwa-manifest-2.json /pwa-manifest-2.json [L]Then Lighthouse doesn’t find any errors and I can install it on my mobile.
-
This reply was modified 4 years, 9 months ago by
hupe13. Reason: code format
-
This reply was modified 4 years, 9 months ago by
The topic ‘Multisite’ is closed to new replies.