# I cannot find resources for a page

**URL:** <https://discourse.gohugo.io/t/i-cannot-find-resources-for-a-page/18679>\
**Category:** support\
**Created:** [May 13, 2019, 11:02pm UTC](https://discourse.gohugo.io/t/i-cannot-find-resources-for-a-page/18679 "2019-05-13T23:02:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Worik](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/worik/32/8624_2.png) [@Worik](https://discourse.gohugo.io/u/Worik)\
**Post date:** [May 13, 2019, 11:02pm UTC](https://discourse.gohugo.io/t/i-cannot-find-resources-for-a-page/18679/1 "2019-05-13T23:02:31Z")

</div>

tl;dr I have defined a type and a layout. In the layout html I cannot find any resources. (`.Resources.Match "*.*"` returns nothing AFAICT)

I am new to hugo and struggling a bit.

In the html for my layout I tried:

```auto
        {{ range .Resources.Match "*.*" }}
        <p> Resource <span> {{ .Name }} </span> </p>
        {{ end }}

```

(and variations on that theme) and there are no results.

I have some confusion over `branch` and `leaf` bundles. I have read [the docs](https://gohugo.io/content-management/page-bundles/#readout) but I think this is a leaf bundle being `Collection of content and attachments for single pages` but I am lost.

The whole story follows

My type `image_details` is defined with a entry in the theme under `layouts/image_details`

There are two files in there:  
`layouts/image_details/image.html` defining the layout  
`layouts/image_details/index.html` This as far as I can tell does nothing.

Over in my content I have three files and a directory.  
`content/image_details/dog.md`  
`content/image_details/cat.md`  
`content/image_details/_index.md` Breaks every thing if `index.html`

The directory has two files  
`content/image_details/images/dog.jpg`  
`content/image_details/images/cat.png`

The contents of dog.md

```auto
---
title: "A Picture of a Dog"
date: 2019-05-13T22:22:48Z
draft: true
layout: image
image: dog.jpg
url: dog
---

# Dog

```

cat.md

```auto
---
title: "A Cat Picture"
date: 2019-05-08T06:17:05Z
draft: false
image: cat.png
layout: "image"
url: cat
---

# A Cat

```

---

<div class="post-metadata">

**Author:** ![Grob](https://avatars.discourse-cdn.com/v4/letter/g/f14d63/32.png) [@Grob](https://discourse.gohugo.io/u/Grob)\
**Post date:** [May 14, 2019, 8:45am UTC](https://discourse.gohugo.io/t/i-cannot-find-resources-for-a-page/18679/2 "2019-05-14T08:45:47Z")

</div>

Hi!

Could you try to move the contents of `dog.md` to `/content/dog/index.md` and images into the same folder and see if it works?

---

<div class="post-metadata">

**Author:** ![Grob](https://avatars.discourse-cdn.com/v4/letter/g/f14d63/32.png) [@Grob](https://discourse.gohugo.io/u/Grob)\
**Post date:** [May 14, 2019, 11:46am UTC](https://discourse.gohugo.io/t/i-cannot-find-resources-for-a-page/18679/3 "2019-05-14T11:46:10Z")

</div>

@kaushalmodi just wrote this in [another post](https://discourse.gohugo.io/t/confusion-about-branch-bundle/18689/3)

> .md files other than the index.md in leaf bundles become page resources (something that a branch bundles cannot have), and so they don’t render to HTML directly.

This should make things clearer.

---

<div class="post-metadata">

**Author:** ![Worik](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/worik/32/8624_2.png) [@Worik](https://discourse.gohugo.io/u/Worik)\
**Post date:** [May 14, 2019, 11:22pm UTC](https://discourse.gohugo.io/t/i-cannot-find-resources-for-a-page/18679/5 "2019-05-14T23:22:42Z")

</div>

> [@Grob](#):
>
> Could you try to move the contents of `dog.md` to `/content/dog/index.md` and images into the same folder and see if it works?

No it does not help, it is worse.  
I now no longer get the template `image.html` at all.

---

<div class="post-metadata">

**Author:** ![Grob](https://avatars.discourse-cdn.com/v4/letter/g/f14d63/32.png) [@Grob](https://discourse.gohugo.io/u/Grob)\
**Post date:** [May 15, 2019, 9:06am UTC](https://discourse.gohugo.io/t/i-cannot-find-resources-for-a-page/18679/6 "2019-05-15T09:06:24Z")

</div>

Then you should probably share your source code/repository.

It works when I use `/content/dog/index.md` in my local setup.
