Join the AMA (Ask Me Anything) with the Firefox leadership team to celebrate Firefox 20th anniversary and discuss Firefox’s future on Mozilla Connect. Mark your calendar on Thursday, November 14, 18:00 - 20:00 UTC!

為了改善您的使用體驗,本網站正在進行維護,部分功能暫時無法使用。若本站的文件無法解決您的問題,想要向社群發問的話,請到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 發問,我們的社群成員將很快會回覆您的疑問。

搜尋 Mozilla 技術支援網站

防止技術支援詐騙。我們絕對不會要求您撥打電話或發送簡訊,或是提供個人資訊。請用「回報濫用」功能回報可疑的行為。

了解更多

Animated GIFs immediately turn black. Why?

  • 11 回覆
  • 2 有這個問題
  • 10 次檢視
  • 最近回覆由 Mugsy

more options

Whenever I include an animated GIF in a tweet on Twitter, it displays for a split second then instantly turns/stays black and I have no idea why.

It does not matter if it's a GIF made by me or if I select one from the menu.

The problem is still there in Safe Mode.

Chrome (on the same computer) does not have this problem.

Animated GIFs on web pages display fine. ONLY animated GIFs *I* post turn black and ONLY in Firefox.

Whenever I include an animated GIF in a tweet on Twitter, it displays for a split second then instantly turns/stays black and I have no idea why. It does not matter if it's a GIF made by me or if I select one from the menu. The problem is still there in Safe Mode. Chrome (on the same computer) does not have this problem. Animated GIFs on web pages display fine. ONLY animated GIFs *I* post turn black and ONLY in Firefox.

所有回覆 (11)

more options

If you use extensions ("3-bar" menu button or Tools -> Add-ons -> Extensions) that can block content (Adblock Plus, NoScript, Disconnect, Ghostery, Privacy Badger, uBlock Origin) always make sure such extensions do not block content.

Firefox shows the shield icon at the left end of the location/address bar in case Content Blocking is blocking content.

  • click the shield icon for more details and possibly disable the protection

You can check the Web Console about what content is blocked

more options

Thanks for the reply.

A built-in security issue seems like a reasonable possibility. I've launched Firefox in "Safe Mode" and it didn't help, so it can't be a plug-in.

I tried switching off my Ad-blocker, but it didn't help. I clicked the "Shield" and tried turning off blocking and granting all permissions, but it didn't help. :(

more options

Are these real GIF images or GIFV files that are actually MP4 video files?

Some websites might be converting such a GIF image automatically and you may not have support to play these files.

You can open the YouTube test page to check support in Firefox for playing HTML5 media.

You can check the Web Console (Tools -> Web Developer) for media related messages.

You can check the Network Monitor to see if content is blocked or otherwise fails to load.

If necessary use "Ctrl+F5" or "Ctrl+Shift+R" (Mac: Command+Shift+R) to reload the page and bypass the cache to generate a fresh log.

more options

Thanks for the reply. I appreciate the feedback.

It's hard to tell if the GIFs are true GIFs, though when I upload GIFs I created myself (frame animation), they do the same thing (show a single frame, Twitter overlays a "Play" button, and the image goes black.)

The YouTube test page says all formats are supported.

I redisplayed the GIF in Twitter and opened the web console. This caught my eye (an error followed by a Warning):

Content Security Policy: Ignoring ‘x-frame-options’ because of ‘frame-ancestors’ directive. Content Security Policy: The page’s settings blocked the loading of a resource at inline (“script-src”).

I'm not sure if this is the problem, but it seems probable. Not sure how I'd fix that though. Thx.

由 Mugsy 於 修改

more options

Can you post a link to a publicly accessible page (i.e. no authentication or signing on required)?

more options

Here is one of my posts this is occurring on (image appears for less than a second, Twitter puts a "play" button on it, and it turns black):

https://twitter.com/MugsysRapSheet/status/1138429036252794882

more options

I am also experiencing this exact issue, even with GIFs I personally created and uploaded. Works on Chrome, works on other sites, tried clearing cache and cookies, nothing works across multiple computers.

And I notice there has been no response on the issue for over 3 weeks. Is it resolved in some way?

由 Windthin 於 修改

more options

I am also experiencing this exact problem. I click on a GIF, and it goes to a black screen. When doing a network check, it shows that it goes on an indefinite POST, supposedly searching for a jot file... which doesn't exist.

Something within the code is causing Firefox to interpret it as something else.

more options

Twitter converts animated GIFs to MP4 videos. Does everyone's Firefox play MP4 videos normally? YouTube has a test page that probes the formats your Firefox can play -- for MP4, you need a checkmark and blue box for H.264 here:

https://www.youtube.com/html5

more options

Mugsy said

Animated GIFs on web pages display fine. ONLY animated GIFs *I* post turn black and ONLY in Firefox.

That seems unfair. What if you view a tweet in a private window, logged out of Twitter, with a clean cache (private windows don't share cookies or cache with regular windows)?

more options

jscher2000 said

Twitter converts animated GIFs to MP4 videos. Does everyone's Firefox play MP4 videos normally? YouTube has a test page that probes the formats your Firefox can play -- for MP4, you need a checkmark and blue box for H.264 here: https://www.youtube.com/html5

Thx for the reply.

I must update my information that I've only recently noticed *some* GIF's posted by other people (not just me) also turn black as soon as they become "playable" (screen-centered), suggesting only certain *types* of animated GIFs are being converted into some obscure format my Firefox does not support.

I checked the YouTube link and everything is checked. Twitter is the only place I've encountered animated GIFs that won't display.

PS: I'm wondering if size (both K & dimensions) might be an issue?

由 Mugsy 於 修改