본 사이트는 여러분의 사용자 경험을 개선하기 위해 유지 보수를 진행하는 동안 기능이 제한됩니다. 도움말로 문제가 해결되지 않고 질문을 하고 싶다면 Twitter의 @FirefoxSupport 및 Reddit의 /r/firefox 채널을 활용하세요.

Mozilla 도움말 검색

고객 지원 사기를 피하세요. 저희는 여러분께 절대로 전화를 걸거나 문자를 보내거나 개인 정보를 공유하도록 요청하지 않습니다. "악용 사례 신고"옵션을 사용하여 의심스러운 활동을 신고해 주세요.

자세히 살펴보기

Error "a plugin is needed to display this content" for embedded Google map, but no plugin identified.

  • 6 답장
  • 44 이 문제를 만남
  • 1 보기
  • 최종 답변자: outtheairlock

more options

When I try to view a page that has a Google map embedded on the page, I get the error message "a plugin is needed to display this content". However, I don't know what plugin, where to get it, etc. I've tried searching for this issue but haven't been able to come up with anyone else experiencing a similar issue, nor does there seem to be a plugin for Google Maps that I can find.

The page is here: http://osiama.org/lodges#

The map displays when one of the links is clicked in the table.

When I try to view a page that has a Google map embedded on the page, I get the error message "a plugin is needed to display this content". However, I don't know what plugin, where to get it, etc. I've tried searching for this issue but haven't been able to come up with anyone else experiencing a similar issue, nor does there seem to be a plugin for Google Maps that I can find. The page is here: http://osiama.org/lodges# The map displays when one of the links is clicked in the table.

선택된 해결법

I was going to suggest adding type="text/html" into the embed tag but found a discussion saying that doesn't work: http://stackoverflow.com/questions/17688628/firefox-tells-user-they-need-a-plugin-to-display-an-embedded-webpage

Following the cue in that thread, what about placing your embed inside an object tag like this:

<object type="text/html" data="https://www.google.com/maps/embed/v1/place?key=AIzaSyA4e2zvSt_VeKb6u_IMvBSAuIPPINgfzNU&q=Nazzaro+Community+Center&zoom=15" height="300" width="450" frameborder="0" style="border:0;">
  <embed src="https://www.google.com/maps/embed/v1/place?key=AIzaSyA4e2zvSt_VeKb6u_IMvBSAuIPPINgfzNU&q=Nazzaro+Community+Center&zoom=15" height="300" width="450" frameborder="0" style="border:0;">
</object>

So in other words, browsers that can use the object tag will do so, but for those that do not, the embed is still in there. Does that work?

문맥에 따라 이 답변을 읽어주세요 👍 3

모든 댓글 (6)

more options

I'm not sure why, but the site uses <embed> for the map instead of <iframe>.

When Firefox wants to render an <embed>, it needs to know what type of object is being embedded, and the site doesn't supply that information, so you see a generic "I don't know how to handle this" error.

Unfortunately, I don't think there is a quick workaround for you as the end user. If you are the type to tinker, you can manually edit the code of the page in the web console as follows:

  • right-click the plugin message and choose Inspect Element (Q) - the web console will open to the Inspector, with the <embed> element selected (screen shot #1)
  • double-click embed and edit it to iframe, then press Enter to finish the edit
  • Firefox will now load the map (screen shot #2)

This isn't a general fix-all for plugin errors, and ultimately the site will need to change this.

more options

Another possibly is to use a bookmarklet like this to replace the embed by an iframe.

javascript:(function(){var eE=document.querySelectorAll('embed[src*="//www.google.com/maps/"]'),i;for(i=0;E=eE[i];i++){N=document.createElement('iframe');for(j in E.attributes){A=E.attributes[j];if((A.name!=undefined)&&(A.value!=undefined)){N.setAttribute(A.name,A.value)}}E.parentNode.replaceChild(N,E)}})()
more options

It's using <embed> at the moment because the map doesn't load or render correctly when it's embedded using an iframe. The map loads correctly with the embed tag in IE and Chrome, so it's just Firefox that is causing the issue.

Is there something I can add to help Firefox be able to identify the object better?

more options

선택된 해결법

I was going to suggest adding type="text/html" into the embed tag but found a discussion saying that doesn't work: http://stackoverflow.com/questions/17688628/firefox-tells-user-they-need-a-plugin-to-display-an-embedded-webpage

Following the cue in that thread, what about placing your embed inside an object tag like this:

<object type="text/html" data="https://www.google.com/maps/embed/v1/place?key=AIzaSyA4e2zvSt_VeKb6u_IMvBSAuIPPINgfzNU&q=Nazzaro+Community+Center&zoom=15" height="300" width="450" frameborder="0" style="border:0;">
  <embed src="https://www.google.com/maps/embed/v1/place?key=AIzaSyA4e2zvSt_VeKb6u_IMvBSAuIPPINgfzNU&q=Nazzaro+Community+Center&zoom=15" height="300" width="450" frameborder="0" style="border:0;">
</object>

So in other words, browsers that can use the object tag will do so, but for those that do not, the embed is still in there. Does that work?

more options

This seems to have solved the problem. Thanks so much!

more options

Oop. Spoke slightly too soon - while the map displays, it encounters the original issue that I was trying to avoid when using iframes in the first place: the map doesn't center correctly. For some reason, using embed tags on every other browser solves this issue, but the object tag doesnt for Firefox.

(Usually Firefox is the last browser to give me problems, yeesh.)