Hello guys, I made a redirect via Wix Location, to an external page, but I’m having trouble maintaining a url of my site when redirecting. I want to redirect and maintain my domain, not the external url.
Do you know how to do this? Help me please?
Hi there …
If you mean redirect to the same domain, only use the slash ( / ) instead of writing the entire domain:
wixLocation.to('/home'); // Internal
wixLocation.to('https://google.com/maps'); // External
And if you mean you want to redirect visitors to external sites by opening a new tab with wixLocation, then it’s not possible.
Hope this helps~!
Ahmad