Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add special flag to CMS preview requests #4960

Closed
wants to merge 1 commit into from

Conversation

IgorNadj
Copy link
Contributor

This affects the iframe used in the CMS for page previews. With this change, we can have the page behave differently based on whether it's a preview or not. The page itself would have to check for the parameter, nothing is done automatically.

Our specific use case is to prevent redirecting to another page, as it would normally. However this may also be useful in e.g. plastering a PREVIEW message, or having other preview-specific content.

This affects the iframe used in the CMS for page previews. With this change, we can have the page behave differently based on whether it's a preview or not. The page itself would have to check for the parameter, nothing is done automatically.

Our specific use case is to prevent redirecting to another page, as it would normally. However this may also be useful in e.g. plastering a PREVIEW message, or having other preview-specific content.
@tractorcow
Copy link
Contributor

It's not going to work, however, if you navigate to another page from the preview, is it? E.g. viewing page A, click page B in the menu, and the CMS interface + preview updates to page B. I suppose it's still good for the initial page, so it's probably ok to merge.

Since this is a new feature, you'll need to put this in the 3 branch, since 3.1 is only accepting critical bugfixes (and 3.2 and 3.3 is only bugfixes too). Can you please re-create on the 3 branch?

@IgorNadj
Copy link
Contributor Author

I've just tested it quickly on my machine and it sends CMSPreview=1 in the scenario you describe, where you navigate to another page in the site tree.

Have re-created PR here: #4967

Thanks

@tractorcow
Copy link
Contributor

Closed with #4967

@tractorcow tractorcow closed this Jan 22, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants