- Optimizely Web Experimentation
- Optimizely Performance Edge
Are you unable to log into a page that is password-protected, session-specific, or behind basic authentication with the Optimizely Web Experimentation editor? If your site is password-protected, behind basic authentication, or requires session-specific information to access certain pages, those pages do not immediately load in the editor.
Password-protected pages and pages behind basic authentication might include Intranet pages, staging sites behind firewalls, and pages that are gated or available only to logged-in visitors. Pages that require session-specific information to load include shopping carts.
To give the Optimizely Web Experimentation editor access to the necessary cookies or session-specific information it needs to load the page correctly:
- Open your site in a browser tab and go to the page you want to edit. To get to the page, you might need to log in, complete a portion of a form or add an item to your cart if you are trying to load a checkout page. Take the exact steps that get you to the exact page that you want to load in the editor.
- Copy the URL of the page.
- Load Optimizely Web Experimentation in an adjacent browser tab where you had the page open.
- Create an experiment using the copied URL of the page you want to test.
Why does this technique work? The editor loads the page as it would appear if you went directly to the URL in another tab. If you can repeatedly load the page into a separate tab outside of Optimizely Web Experimentation, Optimizely Web Experimentation should be able to load the page within the editor.
What's going on? The key is to let Optimizely Web Experimentation retrieve session-specific information from the browser. If this information is passed through cookies, using an adjacent tab or the same tab will work. If the session-specific information is passed through Session Storage, you need to load the editor in the same tab where you just loaded your page.
If you still cannot see the page after following these instructions (for example, your cart is still empty or you are not logged in on the page in the editor), the session data on your site may not be stored in cookies or session storage. This means the session data is not available from within the editor. If you cannot use Interactive mode to go to the page you want to edit, you need one of these two alternate options to create variation code:
- Option 1 – Separately host a static HTML version of the page and load it into the editor. You can then make changes to that page using the Visual Editor. This option requires help from a developer.
- Option 2 – If you are familiar with jQuery, use the developer console in your browser to make changes and see them reflected on your live page. Then, copy that jQuery into the experiment's variation code.
These two options work because the editor acts as a template for the changes you want make, but does not dictate your experiment targeting. Target URLs to choose where your experiment runs dictates exactly where the experiment will run.
Troubleshoot other page-loading issues
- If you see a warning that starts with "We have loaded your site using compatibility mode," you may be encountering an issue with mixed content. See Compatibility mode warning and mixed content in the editor.
- If you try to load content that's in an iframe, see Cannot edit iframes in the editor.
- Update your site's Content Security Policies (CSP)
- For issues with editor page-loading in general, see Pages not loading in the editor.