Skip to content

Live Preview shows blank preview when using subdomain #584

Closed

Description

@avnerw

I have tested this on an upgraded site from 5.3.2 to 6 beta (using MSM), as well as a new EE6 beta installation (using only the preinstalled Default Site).

  1. Under System Settings, when the URL and Path Settings -> Default base URL is set to https://domain.com/sub, the Live Preview shows the blog page.

  2. When I change the above settings to https://sub.domain.com, the Live Preview shows a blank page.

In both cases, the actual site pages all work perfectly with both settings 1. and 2 above, only the preview does not show in case 2 above.

How to replicate:

  • Install EE6 beta with Default Site.
  • Setup a subdomain on the main domain and make sure the subdomain url works.
  • Do 1 and 2 above, and try the preview in both cases.

Let me know if you need further details.

Activity

  1. avnerw commented on Oct 22, 2020

    @avnerw
    Author

    I should also add that on 5.3.2 using the same test as above with or without subdomain, both cases the live preview works.

  2. intoeetive commented on Oct 23, 2020

    @intoeetive
    Contributor

    @avnerw can you check if you have any warning error messages in browser developer console when opening live preview on subdomain? I think you might be restricted because of cross-domain issues

  3. avnerw commented on Oct 23, 2020

    @avnerw
    Author

    @intoeetive I do get the cross-domain error plus another one.
    Although in EE5.3.2 this works fine without any Cross-Origin erros.

    Here it is (replaced my real domain with sub.domain.com):

    Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://sub.domain.com/index.php?ACT=26&channel_id=2&entry_id=14. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing).

    Uncaught admin.php:8115:5
    Underscore 2

    delay

  4. intoeetive commented on Oct 25, 2020

    @intoeetive
    Contributor

    @avnerw - thank you, I was able to replicate the issue. Because the approach to live preview has changed in EE6, we might eventually classify this as a limitation, but for now I'm accepting it as a bug.

  5. added
    Bug: Accepted
    on Oct 25, 2020
  6. ops-andy commented on Nov 25, 2020

    @ops-andy
    Contributor

    resolved in v6-beta4

  7. added a commit that references this issue on Oct 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug: AcceptedEE6

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions