Multisite Customizer Error - "s" added to end of url

I keep getting an error, or at least I think it’s an error. The
reason for “thinking” it’s an error is because it’s not the typical
php error where the file and line # are printed on the page.

Basically my setup is: I have a subdomain (of a
multisite install) that is using the Sage theme (tried both 8.5 &
9). I do have error reporting turned on.

NOTE: no errors are reported when using the dashboard or visiting the my-subdomain.dev
site locally. However, ONLY when using the Customizer (specifically in
development…haven’t tried production or staging yet) I get the
following error using the web browsers console:

`SyntaxError: expected expression, got '<'`

I’m confused why the subdomain is having an “s” added to the end of the url like so:

`<link rel='dns-prefetch' href='//my-subdomain.devs' />`

I’ve tried to suppress the dns-prefetch with little luck. Again, no php error is being printed on screen.

My feeling is that either the Customizer GLOBAL variables are not
getting passed to the templates and/or my Customizer (customizer.php
& .js) files are not properly namespaced.

I must confess that I’m not a pro when it comes to javascript.

Anyways…

any suggestions, thoughts and or insights that you might have would GREATLY GREATLY be appreciated.

Sounds like you have a PHP error somewhere on your page. Do you have error reporting turned on / can you check your error log?

edit: I see you said you have error reporting turned on. Are you positive — if you purposely make an error in your code are you seeing that reflected on the site?

Can you provide the contents of the customizer related files that you’ve made modifications to?

It was a templating issue. The header was getting load more than once. :frowning:

At least for now, I think I’m back on track. Thanks again!