Questions tagged [live-preview]

Craft CMS allows editors to preview their content as they create and edit. This tag relates specifically to using and integrating with the live preview feature.

Filter by
Sorted by
Tagged with
0 votes
1 answer
113 views

Multi-site entries have incorrect preview target

I have a problem with preview links in a Craft multi-site configuration. We’re on Craft 3.7.x and have two sites: default and staff. Each site is configured with its own base URL, the default site is ...
Dalton Rooney's user avatar
1 vote
1 answer
60 views

Matrix content disappears in Live Preview when updated

I'm having an issue where, if I edit any matrix content in Live Preview, all matrix content disappears. When I first open preview, any existing matrix content will display properly, but as soon as I ...
artmem's user avatar
  • 1,012
0 votes
0 answers
81 views

Unclear on Live Preview, multisite, Craft 3.4

My homepage is assembled from a set of entries, so creating Live Preview for a single one of those entries isn't helpful. I am unclear on how to create a Live Preview for all the entries in a section. ...
4midori's user avatar
  • 606
1 vote
0 answers
254 views

Craft CMS Headless - Preview mode

I'm new on craft and I'm using headless mode with a nextJs frontend application. I've tried to configure the preview mode to load the frontend, but I didn't find how to do that. The frontend ...
William Luis Alberton's user avatar
1 vote
1 answer
230 views

No live preview & SEO plugin cannot find content on page

When I try to live preview my craft site the content of the live preview is blank: This is happening for all pages. I have set the template file for the page to use: I am running Craft Solo 3.6.12 ...
Wally's user avatar
  • 333
2 votes
1 answer
223 views

"Single" Entry page gives 404, even though it's enabled

I added a new Single Entry on my site and populated it with content. When I try to access it at the URL I set, it only returns a 404 error, as if the page were disabled. It's not disabled, though. I ...
GDP2's user avatar
  • 141
1 vote
1 answer
41 views

Existing contents get deleted on Live Preview when adding new content on a matrix field

When I add a new content for a matrix block field on an existing entry, all its previous contents gets deleted from the Live Preview, except for the editor which still has the previous contents. And ...
Honey Jean Cariliman's user avatar
1 vote
1 answer
755 views

Headless Live Preview with Gatsby

I am following Andrew Welch's post here - https://twitter.com/nystudio107/status/1168220713158942720?lang=en I used the gatsby-config.js file he shared here - https://gist.github.com/monachilada/...
fxfuture's user avatar
  • 269
4 votes
1 answer
2k views

How do you set up live preview for headless Craft CMS installs connected to Gatsby?

How do you set up live preview for headless Craft CMS installs connected to Gatsby?
Anonymous's user avatar
2 votes
1 answer
925 views

Headless CraftCMS: How can I tell Craft to load live preview from a different (sub)domain?

I will be using CraftCMS (Craft Solo 3.3.18.4) in headless mode as the backend for a Rails app. The Craft instance lives on a different subdomain. How do I instruct craft to use the rails app URI ...
aaandre's user avatar
  • 155
1 vote
1 answer
38 views

Fetch locale entries does not work in Live Preview

I need to display booth local and localized entries in the same page. So I fetch the different localized entries like this : {% set localeEntry = craft.entries.id(myEntry.id).site('default').one() %} ...
scandella's user avatar
2 votes
1 answer
111 views

Multisite, second language Live Preview not working

I have an English site - https://dev.mysite.com and a Japanese site - https://dev.mysite.com/jp. Live preview works great for the English site, but the Japanese site has the following error: Mixed ...
Kelly B's user avatar
  • 76
1 vote
1 answer
407 views

Live Preview not showing content, Craft 3

I use the same templates for live preview as for the front end. Until a recent change in Craft 3, they worked fine for live preview, then they stopped showing most fields. I use a lot of includes to ...
4midori's user avatar
  • 606
1 vote
1 answer
87 views

On multisite setup, currentUser not true in LivePreview

On multisite setup, I have problem to get LivePreview working (Craft 3.3.4). I have one domain live, other not, so it displays Maintenance Page. But I need the editors to edit the entries on that ...
klaxon's user avatar
  • 65
1 vote
1 answer
2k views

Where to enter URL for Live Preview in Craft 3?

Pretty sure I've seen where you can enter the URL for an entry type so Craft knows what page to display during live preview. But I can't find that now. I'm looking in the entry types, and I can't ...
BBaysinger's user avatar
2 votes
2 answers
843 views

"Template not found" in live-preview

I am using docker for my local webdev and am new to Craft CMS. Currently I have a simple setup running, however, my Live-Preview does not seem to work and throws the "Template not found" error. Yet, ...
Ignism's user avatar
  • 21
1 vote
1 answer
1k views

Refused to display/connect when previewing entry on multi-site setup

I run a multi-site setup with four sites; one on unicorn.com and one on all-your-base.com. The way Craft CMS licensing works, you can run multiple sites on different domains on the same license/...
nitech's user avatar
  • 679
2 votes
1 answer
121 views

Navigation is throwing Twig error when trying to 'preview' a disabled entry

I have an entry that needs to be disabled until the content is finalized. I am not able to 'preview' the entry unless I enable it. If I remove the navigation code, 'preview' will work on the disabled ...
user9494's user avatar
2 votes
1 answer
768 views

Live Preview not loading - https / http conflict

My live preview isn't loading. I'm getting the following error: Mixed Content: The page at 'https://www.site.com/admin/entries/pages/611-title' was loaded over HTTPS, but requested an insecure ...
artmem's user avatar
  • 1,012
1 vote
0 answers
139 views

Multi site live preview not working on index page

I'm on Craft 3.1.17.2 My multisite setup is using different domains. If I'm on a.com, I can Live Preview everything on b.com fine, except the homepage. I get the error Access to XMLHttpRequest at '...
mijewe's user avatar
  • 336
2 votes
2 answers
232 views

Craft 3.1.7 live preview multi-site only works on home page

I am running sta-A and site-b on same installation. I have cookie set for domain and have htaccess with CORS origin set to allow *, and also updated the nginx config to allow CORs. I know this last ...
joomkit's user avatar
  • 1,994
1 vote
0 answers
46 views

Can scripts loaded as ES Modules work with Live Preview?

How can a script loaded as an ES module be reinitiated after changes are made in Live Preview? In my experience a script loaded as a module is executed the first time Live Preview is opened, but then ...
Stephen Bowling's user avatar
1 vote
2 answers
587 views

Live Preview for Upcoming Entries

I have an Events section on my site, and to display upcoming and passed events (entries with a status of pending or expired) I manually set the entry in the template: Where the URL is /events/my-...
kmgdev's user avatar
  • 1,125
1 vote
1 answer
155 views

Removing the LivePreview and Share Buttons?

Is there a way to deactivate this functionality? We dont want our clients to use it just yet. I could delete them with my Module's js, but it is triggered after the site is build and the "popping" ...
Leonardo's user avatar
  • 421
1 vote
1 answer
128 views

Why is Live Preview scrolling to the top of page after every change?

Having an issue with Live Preview scrolling to the top of the page in the preview area on every update made (even title field). Narrowed it down to it not being a browser issue as it works plum good ...
Brian Larson's user avatar
1 vote
1 answer
770 views

How can I reload the Live Preview Iframe window using JS

I tried to reload the iframe window using JS but haven't had any luck getting the lp-iframe iframe element, I was thinking I could do it using the Window.Craft object but not sure how? setTimeout(()=&...
Jai Sandhu's user avatar
0 votes
0 answers
82 views

Client not able to access live preview or offline site

Is there any obvious reason why a client is not able to access live preview or an offline site? I've tested the login myself and it works OK. The client has tried using IE on a PC and Chrome and ...
Andrew's user avatar
  • 740
7 votes
2 answers
3k views

Live preview using Vue.js

I'm building a Vue.js site with Craft as the backend, which works pretty well so far. The only thing I can't get to work yet is live preview. Vue-Router relies on the window.location which is flawed ...
Moritz Friedrich's user avatar
1 vote
1 answer
324 views

Live Preview not working in some sections

Live preview works in some sections, but not ones that use routes and have "entries in this section have their own urls" deselected. Is this expected behaviour? Is there any way to use live preview ...
user7150's user avatar
1 vote
1 answer
316 views

Two domains - single install - Live Preview works only on one

I have a multi-site setup on two different domains (actually subdomains) with a single Craft install. I have modified config/general.php file to make it work on both the subdomains. Each domain has ...
hvs's user avatar
  • 283
1 vote
1 answer
151 views

Stop window refreshing in Live Preview?

I am working on LivePreview and the window it's get loaded at every change. It is possible to do that only when I will click the Save button?
user6644's user avatar
3 votes
1 answer
85 views

Apply different classes and styles when in 'live preview' pane

Is there any way of adding a class onto a page body when it is viewed within the 'live preview' pane? I can then use this to make things either show or not show. I want to do this to highlight ...
ianp's user avatar
  • 163
3 votes
1 answer
644 views

Front-end Editing, with Live Preview

I am working on an intranet in Craft CMS. Front-end editing is a very important part of this, and I want to get it perfect. As it is now, the live preview is perfect for what I want, it provides ...
Syversen's user avatar
  • 450
1 vote
0 answers
49 views

DateTime is null in Live Preview

I made a custom field type (two datetime fields for starting / ending time). They have the good value when I loop in value in an entry, but have null value in Live Preview. Do you have an idea of what ...
Nancy's user avatar
  • 21
0 votes
1 answer
67 views

Is it Possible to Use Live Preview with Global Settings

I know that out of the box one cannot use Live Preview with Global Settings. I am wondering if it is possible to write a plugin or in some other manner get Live Preview to work with Global Settings.
Moshe's user avatar
  • 135
2 votes
1 answer
1k views

Live preview not working for CORS

For production site, the backend url is like - 'www.abc-prod.com' While the actual live site url is - 'www.xyz.com' When opening live preview for an entry, page never loads. Instead '301 Moved ...
Amey Dahale's user avatar
1 vote
2 answers
220 views

Live Preview fails to load

Live preview is not working. The following error appears in Inspect Element (Safari). It then times out and generates a whole bunch of can't load errors. but this appears to the root of those ...
Hellyar's user avatar
  • 911
1 vote
2 answers
434 views

Live Preview failing in Safari and Firefox only

New Craft user here and I am working on wrapping up my first Craft site and am running into a Live Preview error. When Live Preview is activated in either Firefox or Safari, I just get a blank white ...
Jesse O'Neill's user avatar
1 vote
1 answer
382 views

Does Google Analytics track Live Preview 'page views'?

Will Google Analytics be recording page views / events from within a Live Preview? And if so, is there a way to prevent this from happening? My understanding is that with Google Analytics you can set ...
Mike Vaux's user avatar
  • 480
2 votes
0 answers
166 views

Live Preview not showing correct content when using single page app with JavaScript

So I am creating a website using Craft with JavaScript for making it a single page app. I load my layout which then calls the pages which works well. The only problem is that when viewing pages ...
nickGR's user avatar
  • 197
2 votes
1 answer
265 views

.find() not working with live preview?

I have an Entry Type with a field called Gallery with a handle of gallery. Here are two examples of how I can access the Gallery field in a template: {% set images = entry.gallery %} {% set images = ...
Peter Tell's user avatar
  • 1,828
4 votes
2 answers
556 views

Is there a way a plugin can watch for live preview updates?

I'm working on a site that involves taking a URL and then getting information about that URL using an API. The URL is entered into a field in a Matrix block, and then another field in the same Matrix ...
Gavin Anderegg's user avatar
0 votes
1 answer
242 views

Live Preview not working - showing home page instead

I've got a Structure entry, enabled, but Live Preview (or just viewing the page on the public site) shows the home page instead. Might I have a setting incorrect? Edit: It looks like previewing any ...
4midori's user avatar
  • 606
2 votes
1 answer
449 views

Live Preview only works with published entries

We have a site where Live Preview only works with entries that have been previously published. When trying to preview entries we're working on (or drafts), we see either the latest entry for that ...
Mike's user avatar
  • 699
1 vote
3 answers
963 views

Show Live Preview even if whole page is disabled

The whole page is disabled in the backend. Like in this screenshot: Now I can't see anything in the Live Preview. My code starts with: {% for entry in craft.entries.section('aboutus') %} If I set ...
Jonathan Schiffner's user avatar
1 vote
1 answer
208 views

Live Preview error when entry is disabled

When the entry is disabled, the Live Preview only shows things which are outer of the main loop. This is a part of my code: {% include "header.html" %} {% for entry in craft.entries.section('...
Jonathan Schiffner's user avatar
2 votes
1 answer
492 views

Live Preview in different languages on different top level domains

Our website offers three different languages. Each language has it own top level domain (example: domain.de, domain.it, domain.fr). Everything works like it should, except the Live Preview function. ...
Tom Bauer's user avatar
  • 1,327
0 votes
1 answer
56 views

My live preview for blog entries is not working on my computer, but is working for my account on other computers

When I go to live preview to view my blog entry in draft mode, all I see is a white screen. My co-workers have tested under my account on their computers and it works just fine. Does anyone have any ...
Bri's user avatar
  • 1
1 vote
1 answer
342 views

Live Preview and CDN caching

We have a problem with using Live Preview on a site that uses CDN caching [CloudFront]. When opening Live Preview a POST is sent to the actual page URL containing the information and the response is ...
graney's user avatar
  • 173
1 vote
2 answers
722 views

No live preview available when entry status is set to disabled?

I have a few entries which are set to disabled. It seems that the live preview is not working then. It only works when the entry status is enabled. This seems more like a bug than a feature, right? ...
Tom De Smet's user avatar
  • 1,456