A Facebook Feed Pro lightbox that jumps to the raw image usually conflicts with another plugin. The known causes.
Would you like to fix a Facebook feed lightbox that opens the raw image file, shows a thin line instead of your photo, or doesn’t load comments and thumbnails?
In this guide, we’ll walk you through each cause and how to fix it. All you need is a feed in Facebook Feed Pro where the lightbox isn’t working the way it should.
Requirements: The pop-up lightbox is part of the paid version of Facebook Feed.
Before you get started, make sure Facebook Feed Pro is installed and activated on your WordPress site.
When a visitor clicks a photo, the plugin’s JavaScript file opens the lightbox. For comments, and for the thumbnails of an album or a post with several photos, the lightbox asks your site for more details. It sends this request through your site’s admin-ajax.php file.
If the JavaScript doesn’t run, or something swaps your photo for a placeholder, the lightbox can’t open the photo the way it should. If your site doesn’t answer the requests, the comments and thumbnails stay empty.
First, the lightbox must be turned on for your feed. To check, go to Facebook Feed » All Feeds and edit your feed. On the Customize tab, open the Lightbox section and check that Enable is on.
Note: Version 4.15.0 of the plugin changed the lightbox so that it shows every item when you move through a feed with Next and Prev. Album thumbnails also load again. If you use an older version, update the plugin to version 4.15.0 or higher. Then check the lightbox again.
Here is what we will cover.
- A JavaScript Error Is Stopping the Plugin’s JavaScript
- The Popup Lightbox Doesn’t Display Photos and Displays a Thin Line Instead
- Comments and Thumbnails in the Lightbox Are Not Loading
- A Tracking Plugin Is Taking Over the Image Links
- Fixing the Salient Theme Conflict
- Frequently Asked Questions
A JavaScript Error Is Stopping the Plugin’s JavaScript
If the lightbox doesn’t open at all and your browser opens the raw image file instead, a JavaScript error on your site may be the cause. The error can stop the plugin’s JavaScript from running. Your browser lists these errors in its developer tools.
- Open the page that shows your feed in your browser.
- Open your browser’s Developer Tools.
- Select the Console tab.
- Reload the page and look for errors shown in red.
Each error includes the file it came from. If that file belongs to your theme or to another plugin, start your troubleshooting there. Fixing those errors lets the plugin’s JavaScript file run correctly.
If you don’t see any errors, move on to the next section. To check whether your page loads the plugin’s JavaScript file at all, see our guide on the Load More button not working.
The Popup Lightbox Doesn’t Display Photos and Displays a Thin Line Instead
If the lightbox opens but shows a thin line instead of your photo, a theme or another plugin is most likely replacing the lightbox photo. The replacement is a 1×1 pixel placeholder image. This is most common with lazy load features.
The plugin already tries to put the original photo back when a lazy load feature swaps it. Some lazy load features still get in the way. To check, turn them off.
- If you have a lazy loading plugin installed, temporarily deactivate it.
- If your theme has a lazy load feature built in, open the theme’s options and turn it off.
- Clear the cache of any caching plugin on your site, then reload the page with your feed.
- Click a photo to check whether the lightbox now shows it.
Here are a few lazy load features that can cause this issue.
- In WP Rocket, turn off the lazy load setting for images.
- In the Customizr theme, turn off the option that loads images on scroll.
If the lightbox works with the lazy load feature off, you can leave it off. Some lazy load settings also let you exclude certain images. This keeps lazy loading on for the rest of your site.
Comments and Thumbnails in the Lightbox Are Not Loading
The comments and thumbnails in the lightbox come from requests to your site’s admin-ajax.php file. A security plugin or a setting on your web server can block those requests. The lightbox then opens. The comments and thumbnails never appear.
Before you look for a block, check that comments are turned on for the lightbox. In your feed’s Customize tab, open the Lightbox section and check that Show Comments is on. This setting applies to Timeline posts only.
To check for a block, look for the error in your browser.
- Open the page that shows your feed in your browser.
- Open your browser’s Developer Tools and select the Network tab.
- Reload the page, then click a photo in your feed to open the lightbox.
- Look for a request to
admin-ajax.phpwith a 403 or 500 status.
The Console tab shows the same problem as a line like the one below.
Failed to load resource: the server responded with a status of 500 (Internal Server Error)
If you see an error like this, check the following.
- If you have a security plugin installed, check its settings for any rule that blocks requests to
admin-ajax.php. You can also temporarily deactivate it to see whether the comments and thumbnails then load. - If you use Wordfence, we have a guide with the steps to fix it. See Wordfence Security Is Blocking Requests.
- Ask your web host’s support team to check whether anything on the server blocks requests to the
admin-ajax.phpfile.
A Tracking Plugin Is Taking Over the Image Links
If clicking a photo opens the lightbox and then immediately sends you to the raw image, the cause may be the WP Slimstat plugin. This is a known issue. WP Slimstat can take over the image links in your feed. To fix this, tell WP Slimstat to leave these links alone.
Here is the first value to enter.
fbcdn.net
Here is the second value, which you only need if the first one doesn’t fix the issue.
cff-lightbox-link,cff-html5-play
- Go to the WP Slimstat settings page.
- Click the Filters tab at the top.
- Scroll down to the Internal and Outbound Links section.
- In the No Callback on URL field, enter the first value.
- If this doesn’t fix the issue, enter the second value in the No callback on classes field above it. Then enter the same value in the Do not Track Classes field below it.
If you use a different tracking or statistics plugin, look for similar settings that stop it from tracking links. Add the same values there.
Fixing the Salient Theme Conflict
If you use the Salient theme, its page transition effect can interfere with the plugin’s links. The links can open as a new page in the theme, with a blank white content area, instead of the lightbox. To fix this, turn off the page transition effect.
- In your WordPress dashboard, open the Salient theme options.
- Find the page transition settings.
- Turn off the page transition effect, then save your changes.
- Reload the page with your feed and click a photo to check the lightbox.
That’s it! You now know how to check for JavaScript errors, turn off lazy loading, and find blocked requests. You also know how to fix links that a tracking plugin or the Salient theme takes over. To fix photos that don’t show in the feed itself, see our guide on images not displaying in the feed.
Frequently Asked Questions
Below, we’ve answered some common questions about the lightbox in your feed.
How do I know which cause I have?
If the lightbox doesn’t open at all and your browser opens the raw image file, start with the JavaScript errors. If the lightbox opens and then sends you to the raw image file, check for a tracking plugin. If clicking a photo opens a blank page in your theme, check the Salient theme. If the lightbox opens with a thin line instead of the photo, check for lazy load features. If the lightbox opens but the comments or thumbnails stay empty, check for blocked requests.
Why don’t the album thumbnails show in my lightbox for some visitors?
This can happen when the GDPR setting limits images and videos until a visitor gives consent. For album feeds, the plugin’s own list of limited features says only the album cover image is available in the lightbox. The plugin loads the thumbnails once the visitor gives consent. To learn how the GDPR setting works, see our GDPR guide.
Why don’t the comments show in my lightbox?
The Show Comments setting in the Lightbox section of your feed’s Customize tab has to be on. It applies to Timeline posts only. If the setting is on and the comments still don’t appear, follow the steps in Comments and Thumbnails in the Lightbox Are Not Loading.
I fixed the cause, but the lightbox still doesn’t work. What should I do?
To fix this, clear the cache of any caching plugin on your site and any cache your web host adds. Then reload the page. Page caches can keep serving an older copy of your page that doesn’t include the fix.