# Adding favicon, site description and publish date to oneboxes

**URL:** https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011
**Category:** UX
**Created:** [11월 13, 2017, 9:07오후 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011 "2017-11-13T21:07:35Z")
**Posts on this page:** 13
**Page:** 1

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [11월 13, 2017, 9:07오후 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/1 "2017-11-13T21:07:35Z")

</div>

One thing I noticed in the “slack” version of onebox is that it has a bunch of info on onebox generic that we do not.

> **[Oldest Winery Found In Eastern Europe After Wine Residue Detected In Jars](https://www.huffpost.com/archive/au/entry/oldest-winery-found-in-eastern-europe-after-wine-residue-detected-in-jars_au_5cd38502e4b0acea9502163e)**
>
> It puts humanity's drinking age at almost 8000 years.

vs

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

Relevant og/html tags:

```plaintext
<link rel="icon" href="http://www.blogsmithmedia.com/www.huffingtonpost.com.au/assets-h4e2c2f72319695bb7776ddc2c3a6b164/favicon.ico?h=cf339f2d96daf6c7aecc6bf0eba0cdac" type="image/x-icon" />
<meta property="og:site_name" content="Huffington Post Australia" />
<meta property="og:type" content="article" />
<meta property="article:published_time" content="2017-11-14T07:58:00+11:00" />

```

The publish time is particularly interesting for `og:type` article, because its news and when it happened makes a big diff. Favicon and nice title are a great little touch.

How do we feel about improving this @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: [11월 13, 2017, 10:36오후 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/2 "2017-11-13T22:36:41Z")

</div>

Yeah this is a good point

 ![image](https://global.discourse-cdn.com/meta/original/3X/3/2/32e83b60f38661917509ffa1c7b22037a9e0f0db.jpg)

I think adding the publish time and date is the easiest, if it is in the metadata.. maybe site name if it is there too, which is easier than pulling `<title>` .. so can we start with that @techAPJ

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [11월 13, 2017, 10:40오후 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/3 "2017-11-13T22:40:58Z")

</div>

Title there is: `Oldest Winery Found In Eastern Europe After Wine Residue Detected In Jars` … we would render it twice if we used title. What we want is `og:site_name` if it is available instead of the actual site URL.

All changes should be fairly simple, and now that we download onebox images they will not incur any cross site talking after processed for favicon.

---

<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: [11월 13, 2017, 10:50오후 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/4 "2017-11-13T22:50:13Z")

</div>

Favicon is going to be much pain and trauma, but I agree on the other two, if the metadata is present, let’s use it.. whitelist that metadata. Handle those first @techAPJ then we can deal with favicon foibles later.

---

<div class="post-metadata">

### Author: ![techAPJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/techapj/32/342990_2.png) [@techAPJ](https://meta.discourse.org/u/techAPJ)
#### Post date: [11월 21, 2017, 6:19오전 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/6 "2017-11-21T06:19:02Z")

</div>

Added site name and published date to generic oneboxes via:

[https://github.com/discourse/onebox/commit/4ca98ccf7035a4e584bc5ebee736d4e54483738f](https://github.com/discourse/onebox/commit/4ca98ccf7035a4e584bc5ebee736d4e54483738f)

Examples:

`http://www.huffingtonpost.com.au/2017/11/13/oldest-winery-found-in-eastern-europe-after-wine-residue-detected-in-jars_a_23275965`

> **[Oldest Winery Found In Eastern Europe After Wine Residue Detected In Jars](https://www.huffpost.com/archive/au/entry/oldest-winery-found-in-eastern-europe-after-wine-residue-detected-in-jars_au_5cd38502e4b0acea9502163e)**
>
> It puts humanity's drinking age at almost 8000 years.

`https://www.vox.com/videos/2017/11/20/16670266/trucking-eld-surveillance`

> **[Automation is coming for truckers. But first, they’re being watched.](https://www.vox.com/videos/2017/11/20/16670266/trucking-eld-surveillance)**
>
> How job surveillance is transforming trucking in America.

`https://www.theverge.com/2017/11/20/16672600/oneplus-5t-smartphone-android-2017-review`

> **[OnePlus 5T review: polished to a T](https://www.theverge.com/2017/11/20/16672600/oneplus-5t-smartphone-android-2017-review)**
>
> In practice, this phone isn’t the total fulfillment of every objective that OnePlus set for itself nor every promise the company has made. But it’s damn close.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [11월 21, 2017, 7:00오전 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/7 "2017-11-21T07:00:59Z")

</div>

I find the styling of the date somewhat rough, can we try something more along these lines?

 ![image](https://global.discourse-cdn.com/meta/original/3X/8/2/82a11a2c1b36bc4d10a7eea3513e3874c80c5b94.png)

Also I kind of wish for a bit more text next to the site title, but maybe its just cause “The Verge” is so short.

@awesomerobot thoughts?

Also how are we localizing dates in onebox now?

---

<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: [11월 21, 2017, 11:00오전 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/8 "2017-11-21T11:00:48Z")

</div>

Also we don’t need to know it was published at 9am on November 20th, 2017.. I think the date alone is sufficient @techapj.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [11월 21, 2017, 11:09오전 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/9 "2017-11-21T11:09:18Z")

</div>

True, you can keep the full time in the tooltip for a nice touch

Ideally we want “3 days ago” but that is a pretty big technical challenge for small amount of gain

---

<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: [11월 21, 2017, 11:09오전 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/10 "2017-11-21T11:09:52Z")

</div>

No, these are baked once, that ‘3 days ago’ would be permanently baked into the post, wouldn’t it? Needs to be an absolute date. I think that’s generally preferable anyway in this case for external data.

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [11월 21, 2017, 11:12오전 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/11 "2017-11-21T11:12:55Z")

</div>

Technically we have a post processor that runs live on every post just like @j.jaffeux plugin works, but totally agree it’s a pretty big pain to implement and email is a problem even if web is straightforward to solve

---

<div class="post-metadata">

### Author: ![techAPJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/techapj/32/342990_2.png) [@techAPJ](https://meta.discourse.org/u/techAPJ)
#### Post date: [11월 21, 2017, 11:25오전 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/12 "2017-11-21T11:25:33Z")

</div>

> [@sam](#):
>
> I find the styling of the date somewhat rough, can we try something more along these lines?

> [@codinghorror](#):
>
> Also we don’t need to know it was published at 9am on November 20th, 2017… I think the date alone is sufficient

> [@sam](#):
>
> you can keep the full time in the tooltip for a nice touch

Done via

[https://github.com/discourse/discourse/commit/753a4fc3697e1f041c9d40e9db5c728ce596c81d](https://github.com/discourse/discourse/commit/753a4fc3697e1f041c9d40e9db5c728ce596c81d)

and

[https://github.com/discourse/onebox/commit/98acf70fe5a8da41f7dd420396e65c8339f40b18](https://github.com/discourse/onebox/commit/98acf70fe5a8da41f7dd420396e65c8339f40b18)

> [@sam](#):
>
> Also how are we localizing dates in onebox now?

I don’t think we are localizing dates in onebox yet. Will investigate more and reply here.

---

<div class="post-metadata">

### Author: ![techAPJ](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/techapj/32/342990_2.png) [@techAPJ](https://meta.discourse.org/u/techAPJ)
#### Post date: [11월 25, 2017, 4:47오후 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/13 "2017-11-25T16:47:08Z")

</div>

Onebox now support favicon as well. Examples:

> **[Oldest Winery Found In Eastern Europe After Wine Residue Detected In Jars](https://www.huffpost.com/archive/au/entry/oldest-winery-found-in-eastern-europe-after-wine-residue-detected-in-jars_au_5cd38502e4b0acea9502163e)**
>
> It puts humanity's drinking age at almost 8000 years.

> **[Client Challenge](https://www.khanacademy.org/science/physics/one-dimensional-motion)**

> **[A Theory of...](https://stackoverflow.blog/2009/05/18/a-theory-of-moderation/?24)**

[https://www.recode.net/2017/11/24/16696602/thanksgiving-black-friday-2017-online-retail-sales-3-billion-adobe?4](https://www.recode.net/2017/11/24/16696602/thanksgiving-black-friday-2017-online-retail-sales-3-billion-adobe?4)

---

<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: [11월 25, 2017, 7:30오후 UTC](https://meta.discourse.org/t/adding-favicon-site-description-and-publish-date-to-oneboxes/74011/14 "2017-11-25T19:30:06Z")

</div>


