# 如何在 Simplecast 中嵌入音频播放器

**URL:** <https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023>\
**Category:** Support\
**Created:** [2018年十二月11日 16:44 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023 "2018-12-11T16:44:51Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![jtbayly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jtbayly/32/119510_2.png) [@jtbayly](https://meta.discourse.org/u/jtbayly)\
**Post date:** [2018年十二月11日 16:44 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/1 "2018-12-11T16:44:52Z")

</div>

I’m really confused why this isn’t embedding an audio player:

[https://simplecast.com/s/7fe152f4](https://simplecast.com/s/7fe152f4)

They support oembed, as can be seen here: [https://oembed.com](https://oembed.com) (search on the page for simplecast).

My first thought is that I need to whitelist it, and it’s just not whitelisted here. However, I turned on “enable inline onebox on all domains” and that didn’t help on my site. Then I tried whitelisting [simplecast.com](http://simplecast.com). That didn’t help either. Any thoughts?

edited to add: appears to work properly on [iframely](http://iframely.com/debug?uri=https%3A%2F%2Fsimplecast.com%2Fs%2F7fe152f4)

---

<div class="post-metadata">

**Author:** ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)\
**Post date:** [2018年十二月11日 17:55 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/2 "2018-12-11T17:55:18Z")

</div>

Their OpenGraph data has a type = `website` …

---

<div class="post-metadata">

**Author:** ![jtbayly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jtbayly/32/119510_2.png) [@jtbayly](https://meta.discourse.org/u/jtbayly)\
**Post date:** [2018年十二月11日 17:57 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/3 "2018-12-11T17:57:26Z")

</div>

Ok… interesting. So, what should it be? I might be able to get them to fix it.

And why does it appear to work properly in iframely?

---

<div class="post-metadata">

**Author:** ![zogstrip](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/zogstrip/32/512781_2.png) [@zogstrip](https://meta.discourse.org/u/zogstrip)\
**Post date:** [2018年十二月11日 18:26 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/4 "2018-12-11T18:26:06Z")

</div>

> [@jtbayly](#):
>
> And why does it appear to work properly in iframely?

Because they use the data from the Twitter Card.

> [@jtbayly](#):
>
> Ok… interesting. So, what should it be? I might be able to get them to fix it.

I think we should properly support Twitter Cards with a type of `player`.

@nbianca, can you add that to your list? We should update our [`WhitelistedGenericOnebox`](https://github.com/discourse/onebox/blob/master/lib/onebox/engine/whitelisted_generic_onebox.rb) to properly detect embeds in [Twitter Cards](https://developer.twitter.com/en/docs/tweets/optimize-with-cards/overview/player-card.html)

---

<div class="post-metadata">

**Author:** ![jtbayly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jtbayly/32/119510_2.png) [@jtbayly](https://meta.discourse.org/u/jtbayly)\
**Post date:** [2018年十二月11日 20:19 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/5 "2018-12-11T20:19:08Z")

</div>

I let them know about the issue. I guess it’s a race to see who can fix it first. 😉

---

<div class="post-metadata">

**Author:** ![nbianca](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nbianca/32/157984_2.png) [@nbianca](https://meta.discourse.org/u/nbianca)\
**Post date:** [2018年十二月18日 17:22 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/6 "2018-12-18T17:22:38Z")

</div>

🙂

[https://github.com/discourse/onebox/pull/390/files](https://github.com/discourse/onebox/pull/390/files)

---

<div class="post-metadata">

**Author:** ![jtbayly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jtbayly/32/119510_2.png) [@jtbayly](https://meta.discourse.org/u/jtbayly)\
**Post date:** [2018年十二月18日 18:14 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/7 "2018-12-18T18:14:58Z")

</div>

Looking forward to trying this!

---

<div class="post-metadata">

**Author:** ![nbianca](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nbianca/32/157984_2.png) [@nbianca](https://meta.discourse.org/u/nbianca)\
**Post date:** [2019年四月24日 16:45 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/8 "2019-04-24T16:45:06Z")

</div>



---

<div class="post-metadata">

**Author:** ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)\
**Post date:** [2019年四月25日 00:20 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/9 "2019-04-25T00:20:41Z")

</div>

Does this work?

https://player.simplecast.com/5932bee4-6bfa-45fd-841a-403103055619

[https://simplecast.com/s/7fe152f4](https://simplecast.com/s/7fe152f4)

Should the above work @nbianca?

---

<div class="post-metadata">

**Author:** ![nbianca](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nbianca/32/157984_2.png) [@nbianca](https://meta.discourse.org/u/nbianca)\
**Post date:** [2019年四月25日 11:10 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/11 "2019-04-25T11:10:44Z")

</div>

Simplecast are not providing twitter cards info anymore, so I had to implement an oembed onebox for them.

[https://github.com/discourse/onebox/pull/403](https://github.com/discourse/onebox/pull/403)

---

<div class="post-metadata">

**Author:** ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)\
**Post date:** [2019年四月25日 23:10 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/12 "2019-04-25T23:10:00Z")

</div>



---

<div class="post-metadata">

**Author:** ![jtbayly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jtbayly/32/119510_2.png) [@jtbayly](https://meta.discourse.org/u/jtbayly)\
**Post date:** [2019年五月6日 21:16 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/13 "2019-05-06T21:16:10Z")

</div>

FWIW, Simplecast recently went through a big change to a new 2.0 codebase. Lots changed. I did tell them recently that their stuff isn’t auto-embedding like they claim.

They say “Use this link to share via social media. It will automatically embed a player in WordPress, Medium, and many other popular sites.” with a link such as this:  
`https://tgd.simplecast.com/episodes/dan-blackman-and-robyn-kanner-the-power-7fe152f4`

It doesn’t work on [Wordpress.com](http://Wordpress.com) or self-hosted Wordpress. Let’s test it again now here on Meta:

https://player.simplecast.com/5932bee4-6bfa-45fd-841a-403103055619

Edit: Looks like it’s working!

---

<div class="post-metadata">

**Author:** ![Seth\_Godin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/seth_godin/32/119667_2.png) [@Seth\_Godin](https://meta.discourse.org/u/Seth_Godin)\
**Post date:** [2019年七月29日 19:56 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/14 "2019-07-29T19:56:34Z")

</div>

在此跨帖转发自关于此问题的稍后[讨论](https://meta.discourse.org/t/radiopublic-player-onebox/112611/2)

看起来 Simplecast 的 Onebox 功能之前运行良好，但现在又无法正常工作了。有什么想法吗？谢谢。

 ![image](https://global.discourse-cdn.com/meta/original/3X/e/e/eeb3bf113873b48fdfeaaff4ad9281a9b3f10ad6.png)

---

<div class="post-metadata">

**Author:** ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)\
**Post date:** [2019年七月30日 06:06 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/15 "2019-07-30T06:06:48Z")

</div>

让我们看看上面发布的旧链接是否仍然能实现一键展开

`https://tgd.simplecast.com/episodes/dan-blackman-and-robyn-kanner-the-power-7fe152f4`

https://player.simplecast.com/5932bee4-6bfa-45fd-841a-403103055619

是的，该链接可以正常使用 @Seth_Godin

该链接与您发布的链接有很大不同，后者是

`https://simplecast.com/s/19cdf3ea`

对比一下

`https://tgd.simplecast.com/episodes/dan-blackman-and-robyn-kanner-the-power-7fe152f4`

---

<div class="post-metadata">

**Author:** ![Seth\_Godin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/seth_godin/32/119667_2.png) [@Seth\_Godin](https://meta.discourse.org/u/Seth_Godin)\
**Post date:** [2019年七月30日 13:43 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/16 "2019-07-30T13:43:13Z")

</div>

我又深入调查了一下。以下是 Simplecast 现在提供链接分享的方式：

[![](https://global.discourse-cdn.com/meta/original/3X/9/1/91055584efeb64452649f5670d8a06be5542e231.jpeg) ](https://dl.dropboxusercontent.com/s/xonneize1wauo92/Screenshot%202019-07-30%2009.42.03.jpg?dl=0)

如您所见，旧模型已不再支持。

不确定这是否在 onebox 路线图内，但这显然是他们做出的一项变更。谢谢。

编辑！等等，这可能行得通……我在 URL 中添加“embed”一词，得到以下内容：

> **[Simplecast -- Let your voice be heard](https://player.simplecast.com/2dc25e97-07ee-4a64-bd14-adc61906ffee)**

---

<div class="post-metadata">

**Author:** ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)\
**Post date:** [2019年七月31日 04:23 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/17 "2019-07-31T04:23:40Z")

</div>

也许我们需要在这里放宽我们要查找的 URL 模式，以包含这个域名 @nbianca？

---

<div class="post-metadata">

**Author:** ![ahd2109](https://avatars.discourse-cdn.com/v4/letter/a/9fc348/32.png) [@ahd2109](https://meta.discourse.org/u/ahd2109)\
**Post date:** [2019年七月31日 18:05 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/18 "2019-07-31T18:05:31Z")

</div>

我来插一句！我迁移到了“新版”Simplecast，以获取更新的 URL，就像你从 TGD 发布的那个一样，@codinghorror，但它仍然显示为普通链接，而不是一键预览卡片。

 ![08%20PM](https://global.discourse-cdn.com/meta/original/3X/d/3/d3e0f2e5d4300ae88c709a898cd643f263157be9.png)

---

<div class="post-metadata">

**Author:** ![ahd2109](https://avatars.discourse-cdn.com/v4/letter/a/9fc348/32.png) [@ahd2109](https://meta.discourse.org/u/ahd2109)\
**Post date:** [2019年八月7日 20:51 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/19 "2019-08-07T20:51:57Z")

</div>

正在检查这个 @codinghorror！！

---

<div class="post-metadata">

**Author:** ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)\
**Post date:** [2019年八月7日 21:18 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/20 "2019-08-07T21:18:06Z")

</div>

当然，@nbianca 可以查看一下是否可以放宽 URL 模式以提高兼容性。

---

<div class="post-metadata">

**Author:** ![ahd2109](https://avatars.discourse-cdn.com/v4/letter/a/9fc348/32.png) [@ahd2109](https://meta.discourse.org/u/ahd2109)\
**Post date:** [2019年八月7日 23:32 UTC](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023/22 "2019-08-07T23:32:19Z")

</div>

谢谢 @nbianca！告诉我我能怎么帮忙。

[下一頁](https://meta.discourse.org/t/how-to-oembed-a-player-for-simplecast-audio/104023.md?page=2)
