# Template update not loading and failing resources

**URL:** <https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687>\
**Category:** Bug\
**Created:** [2015年五月12日 10:47 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687 "2015-05-12T10:47:22Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![nicklasmoeller](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nicklasmoeller/32/116073_2.png) [@nicklasmoeller](https://meta.discourse.org/u/nicklasmoeller)\
**Post date:** [2015年五月12日 10:47 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/1 "2015-05-12T10:47:22Z")

</div>

Hello,

I’ve got at template update on [https://forum.billysbilling.dk/](https://forum.billysbilling.dk/) that just over the night stopped working. Unfortunately, also our logo started to disappear on some requests (403 Forbidden response)

The layout update is taken from [https://meta.discourse.org/t/the-homepage-overview-how-to-make-it-look-more-clean/28623/3](https://meta.discourse.org/t/the-homepage-overview-how-to-make-it-look-more-clean/28623/3) where I’ve made some smaller adjustments, to fit it to our needs.

_`</body>`_

```
<script type='text/x-handlebars' data-template-name='list/topic_list_item.raw'>

  <td class='main-link clearfix'>
    {{raw "topic-status" topic=topic}}
    {{topic-link topic}}

    {{#if controller.showTopicPostBadges}}
      {{raw "topic-post-badges" unread=topic.unread newPosts=topic.displayNewPosts unseen=topic.unseen url=topic.lastUnreadUrl}}
    {{/if}}

    {{raw "list/topic-excerpt" topic=model}}

    <div class='creator'>
        {{~#if topic.creator ~}}
            <a href="/users/{{topic.creator.username}}" data-auto-route="true" data-user-card="{{topic.creator.username}}">{{topic.creator.username}}</a>
            &nbsp;
            {{format-date topic.createdAt format="medium-with-ago"}}
        {{~/if ~}}
        
        {{raw "list/action-list" topic=topic postNumbers=topic.bookmarked_post_numbers className="bookmarks" icon="bookmark"}}
        {{raw "list/action-list" topic=topic postNumbers=topic.liked_post_numbers className="likes" icon="heart"}}
    </div>
  </td>

  {{#if controller.showLikes}}
    <td class="num likes">
      {{number topic.like_count}} <i class='fa fa-heart'></i>
    </td>
  {{/if}}

  {{#if controller.showOpLikes}}
    <td class="num likes">
      {{number topic.op_like_count}} <i class='fa fa-heart'></i>
    </td>
  {{/if}}
  
  <td class="category">
    {{category-link topic.category showParent="true" onlyStripe="true"}}
  </td>

  <td class="num views">
    {{topic.views}}
  </td>

  <td class="num views">
    {{topic.replyCount}}
  </td>

  <td class="last-post">
    <div class='poster-avatar'>
      <a href="{{topic.lastPostUr}}" data-user-card="{{topic.last_poster_username}}">{{avatar topic.lastPoster usernamePath="username" imageSize="medium"}}</a>
    </div>

    <div class='poster-info'>
      <a href="{{topic.lastPostUrl}}">
        {{format-date topic.bumpedAt format="medium-with-ago"}},
      </a><br />
      <span class='editor'><a href="/users/{{topic.last_poster_username}}" data-auto-route="true" data-user-card="{{topic.last_poster_username}}">{{topic.last_poster_username}}</a></span>
    </div>
  </td>
</script>

<script type='text/x-handlebars' data-template-name='topic-list-header.raw'>
  {{raw "topic-list-header-column" order='posts' name='topic.title'}}

  {{#if showLikes}}
    {{raw "topic-list-header-column" sortable='true' order='likes' number='true' forceName='Likes'}}
  {{/if}}

  {{#if showOpLikes}}
    {{raw "topic-list-header-column" sortable='true' order='op_likes' number='true' forceName='Likes'}}
  {{/if}}
  
  {{raw "topic-list-header-column" sortable='true' order='category' forceName='Kategori'}}
  {{raw "topic-list-header-column" sortable='true' number='true' order='views' forceName='Visninger'}}
  {{raw "topic-list-header-column" sortable='true' number='true' order='posts' forceName='Svar'}}
  {{raw "topic-list-header-column" sortable='true' order='activity' forceName='Sidste indlæg'}}
</script>

<script>
  Discourse.TopicListItemView.reopen({
    showCategory: function(){
      return !this.get('controller.hideCategory') &&
        this.get('topic.creator') &&
        this.get('topic.category.name') !== 'uncategorized';
    }.property()
  });

  Discourse.Topic.reopen({
    creator: function(){
      var poster = this.get('posters.firstObject');
      if(poster){
        return poster.user;
      }
    }.property(),
    lastPoster: function() {
      var poster = this.get('posters.lastObject');
      if(poster){
        if (this.last_poster_username === poster.user.username){
          return poster.user;
        } else {
          return this.get('creator');
        }
      }
    }.property('posters'),
    replyCount: function(){
      return this.get('posts_count') - 1;
    }.property(),
    hasReplies: function(){
      return this.get('posts_count') > 1;
    }.property()

  });
</script>

```

_`CSS`_

```
.poster-avatar {
    float: left;
}

.poster-info {
    float: left;
    margin-left: 10px;
}

@media (max-width: 760px) {
    .poster-avatar {
        display: none;
    }
}

@media (max-width: 560px) {
    .topic-list .category {
        display:none;
    }
}

.topic-list .posts {
    width: 640px;
}

.topic-list .num {
    width: 65px;
}

.topic-list .activity {
    width: 180px !important;
}

.category .badge-wrapper {
    line-height: 1.6;
}

.category .badge-category-bg {
    border-radius: 3px;
    line-height: 2.5;
}

.category .badge-category {
    padding: 10px 20px;
}

.category .badge-category-parent-bg {
    border-radius: 3px;
}

.creator .relative-date {
    text-transform: capitalize;
}

```

Unfortunately, this isn’t the first time we’ve had some loading issues (just a guess for the cause), as a hosted Discourse solution. [CDN 503 on user avatars and CSS files](https://meta.discourse.org/t/cdn-503-on-user-avatars-and-css-files/28329)

Anyone able to help me out here? @sam or @codinghorror eventually?

---

<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:** [2015年五月12日 11:13 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/2 "2015-05-12T11:13:47Z")

</div>

> [@nicklasmoeller](#):
>
> I’ve got at template update on [https://forum.billysbilling.dk/](https://forum.billysbilling.dk/) that just over the night stopped working.

I’m afraid the ember update might have broken the template. I’ve disabled it until we fix it. cc @eviltrout

> [@nicklasmoeller](#):
>
> Unfortunately, also our logo started to disappear on some requests (403 Forbidden response)

That’s because the URL it points to is returning 403

```
→ curl -I https://billysbilling.dk/sites/default/files/public/styles/media_thumbnail/public/billys-forum_0.png
HTTP/1.1 403 Forbidden
Content-Type: text/html; charset=iso-8859-1
Date: Tue, 12 May 2015 11:11:11 GMT
Server: Apache/2.2.29 (Amazon)
Connection: keep-alive

```

Might want to take a look at your configuration.

---

<div class="post-metadata">

**Author:** ![nicklasmoeller](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nicklasmoeller/32/116073_2.png) [@nicklasmoeller](https://meta.discourse.org/u/nicklasmoeller)\
**Post date:** [2015年五月12日 11:21 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/3 "2015-05-12T11:21:47Z")

</div>

> [@zogstrip](#):
>
> I’m afraid the ember update might have broken the template. I’ve disabled it until we fix it. cc @eviltrout

Just to be sure - you’ve disabled our template until it’s fixed (it’s indeed disabled now)? Could it be possible that you can notice me when it’s fixed?

> [@zogstrip](#):
>
> That’s because the URL it points to is returning 403
> 
> …
> 
> Might want to take a look at your configuration.

I see that that’s the case (didn’t care to see where our logo was fetched from). It’s on our part, but it seems to be halting. Thanks though 🙂

---

<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:** [2015年五月12日 11:33 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/4 "2015-05-12T11:33:56Z")

</div>

I think changing topic\_list\_item to topic-list-item should fix it

---

<div class="post-metadata">

**Author:** ![nicklasmoeller](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nicklasmoeller/32/116073_2.png) [@nicklasmoeller](https://meta.discourse.org/u/nicklasmoeller)\
**Post date:** [2015年五月12日 11:54 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/5 "2015-05-12T11:54:30Z")

</div>

It’s not working, if you’re meaning on our end - although your suggestion is reasonable, the template is still not updated, whether using underscores or dashes

---

<div class="post-metadata">

**Author:** ![pdx](https://avatars.discourse-cdn.com/v4/letter/p/cdc98d/32.png) [@pdx](https://meta.discourse.org/u/pdx)\
**Post date:** [2015年五月12日 11:54 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/6 "2015-05-12T11:54:40Z")

</div>

I had the same issue and that fixed it for me, thanks!

---

<div class="post-metadata">

**Author:** ![nicklasmoeller](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nicklasmoeller/32/116073_2.png) [@nicklasmoeller](https://meta.discourse.org/u/nicklasmoeller)\
**Post date:** [2015年五月12日 11:58 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/7 "2015-05-12T11:58:55Z")

</div>

And same for me - it appeared my last attempt didn’t save the changes I made. Thanks for contributing, also - and thanks for the solution @sam 😄

---

<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:** [2015年五月12日 12:06 UTC](https://meta.discourse.org/t/template-update-not-loading-and-failing-resources/28687/8 "2015-05-12T12:06:18Z")

</div>


