There is a problem while I am getting the cover image from the page

Hello, I need someone’s help…
I’m trying it by referring to other examples, but I can’t solve it myself.

On the main screen of my website, there are 4 logos and each image is used as a background image when the user ‘hover’ the logo.
So I made 4 image sections in Kirby and tried to bring up each image. It’s okay to bring up the image. But there was an error. (Please check the capture image.)

Is there anyone who can help me?
I need help :frowning:

Link
http://client.1-2-3-4-5.studio/dy/kr

 <?php if ($photographyPage = page('photography')): ?>
        <li class="logobox-one">
        <?php foreach ($photographyPage->children()->listed() as $album): ?>
        <?php if ($cover = $album->cover()): ?>
            <img class="logo-dy" src="<?= $cover->url() ?>" style="background-size: cover; background-position: center center;">
        <?php endif ?>
        <?php endforeach ?>
      <?php endif ?>
            <a class="logo-dy-link" href="http://client.1-2-3-4-5.studio/dy/dy">
     <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 264.71 93.28"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}</style></defs><path class="a" d="M120.52,7.51H154c23.88,0,38.17,14.5,38.17,38.6,0,25.53-14.51,39.27-38.17,39.27H120.52Zm20.29,60.42h9.6c15.38-.33,21.48-6.33,21.48-21.92,0-14.18-7.63-21-21.48-21h-9.6Z"/><polygon class="a" points="241.69 7.5 226.2 39.13 210.72 7.5 187.7 7.5 216.06 56.37 216.06 85.38 236.35 85.38 236.35 56.37 264.71 7.5 241.69 7.5"/><path class="a" d="M14.3,93.28H58.66A31.24,31.24,0,0,0,89.9,62V17.77Z"/><polygon class="b" points="10.61 0 48.12 37.46 85.63 0 10.61 0"/><polygon class="c" points="0 85.77 37.46 48.26 0 10.75 0 85.77"/></svg></a>
        </li>

Could you post the blueprint please? I wonder where all the img tags with the empty src attributes are coming from. Shouldn’t there be only one image per per li element? In that case the foreach loop should be around the li tags rather than inside, but I need to understand the complete structure of your setup.

That’s right. There should be only one image.

main page(home)

title: DY
columns:
  - width: 1/1
    sections:
      pages:
        type: pages
        create: false
        templates:
          - dy
          - dyauto
          - dypower
          - dyinno

  - width: 1/1
    sections:
      albums: sections/albums

sections/albums.yml

type: pages
headline: DY
parent: kirby.page("photography")
size: small
info: "{{ page.images.count }} image(s)"
layout: cards
template: album
empty: No albums yet
image:
  query: page.cover
  cover: true
  ratio: 5/4

models/albums.php

<?php

class AlbumPage extends Page
{
    public function cover()
    {
        return $this->content()->get('cover')->toFile() ?? $this->image();
    }
}

albums.yml

title: Album

icon: 🖼

status:
  draft: true
  listed: true

columns:
  - width: 1/3
    fields:
      cover: fields/cover
      headline:
        type: text
        placeholder: "{{ page.title }}"
        help: Leave empty to use the title as headline
      subheadline:
        type: text
      text:
        type: writer
      tags: true

  - width: 2/3
    sections:
      dyimages:
        type: files
        layout: cards
        template: image
        info: "{{ file.dimensions }}"
        image:
          ratio: 5/4
          cover: true
        min: 1
        size: small

  - width: 1/1
    sections:
      allfiles:
        headline: file archive
        type: files
        layout: cards
        # template: image
        info: "{{ file.dimensions }}"
        image:
          ratio: 5/4
          cover: true
        size: small
        help: 이미지와 파일을 관리합니다.

What I’m still missing is how you create logogox-one, -two, -three, -four, which should probably be the elements created through the loop?

I’m sorry. The code is too long, so I only wrote the code for the first logo.
I’ll write down the full code. Four logos are not created by copying one logo.

<div class="logobox-set">
    <ul class="logobox">
      <?php if ($photographyPage = page('photography')): ?>
        <li class="logobox-one">
        <?php foreach ($photographyPage->children()->listed() as $album): ?>
        <?php if ($cover = $album->cover()): ?>
            <img class="logo-dy" src="<?= $cover->url() ?>" style="background-size: cover; background-position: center center;">
        <?php endif ?>
        <?php endforeach ?>
      <?php endif ?>
            <a class="logo-dy-link" href="http://client.1-2-3-4-5.studio/dy/dy">
     <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 264.71 93.28"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}</style></defs><path class="a" d="M120.52,7.51H154c23.88,0,38.17,14.5,38.17,38.6,0,25.53-14.51,39.27-38.17,39.27H120.52Zm20.29,60.42h9.6c15.38-.33,21.48-6.33,21.48-21.92,0-14.18-7.63-21-21.48-21h-9.6Z"/><polygon class="a" points="241.69 7.5 226.2 39.13 210.72 7.5 187.7 7.5 216.06 56.37 216.06 85.38 236.35 85.38 236.35 56.37 264.71 7.5 241.69 7.5"/><path class="a" d="M14.3,93.28H58.66A31.24,31.24,0,0,0,89.9,62V17.77Z"/><polygon class="b" points="10.61 0 48.12 37.46 85.63 0 10.61 0"/><polygon class="c" points="0 85.77 37.46 48.26 0 10.75 0 85.77"/></svg></a>
        </li>


        <li class="logobox-two">
      <?php if ($photographyPage = page('photography')): ?>
        <?php foreach ($photographyPage->children()->listed() as $autoalbum): ?>
        <?php if ($cover = $autoalbum->covertwo()): ?>
            <img class="logo-dypower" src="<?= $cover->url() ?>" style="background-size: cover; background-position: center center;">
        <?php endif ?>
        <?php endforeach ?>
      <?php endif ?>
            <a class="logo-dy-power-link" href="http://client.1-2-3-4-5.studio/dy/dy-power"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 675.3 93.3"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}.d{fill:#2ea7e0;}</style></defs><path class="a" d="M120.5,7.5H154c23.9,0,38.2,14.5,38.2,38.6,0,25.5-14.5,39.3-38.2,39.3H120.5Zm20.3,60.4h9.6c15.4-.3,21.5-6.3,21.5-21.9,0-14.2-7.6-21-21.5-21h-9.6Z"/><polygon class="a" points="241.7 7.5 226.2 39.1 210.7 7.5 187.7 7.5 216.1 56.4 216.1 85.4 236.4 85.4 236.4 56.4 264.7 7.5 241.7 7.5"/><path class="a" d="M14.3,93.3H58.7A31.18,31.18,0,0,0,89.9,62.1h0V17.8Z"/><polygon class="b" points="10.6 0 48.1 37.5 85.6 0 10.6 0"/><polygon class="c" points="0 85.8 37.5 48.3 0 10.8 0 85.8"/><path class="d" d="M671,64.9a19.56,19.56,0,0,0-1.2-7.6,14.87,14.87,0,0,0-2.9-5,10.75,10.75,0,0,0-3.8-2.8,16.57,16.57,0,0,0-3.8-1.1v-.2c.7-.2,1.7-.7,3.1-1.3a15.09,15.09,0,0,0,4.3-3.2,19.27,19.27,0,0,0,3.8-5.9,22.35,22.35,0,0,0,1.6-9.2c0-6.6-2.1-11.8-6.4-15.5S655,7.5,646.4,7.5H609.2V85.4H623v-32h20.1a20.36,20.36,0,0,1,7.7,1.2,9.75,9.75,0,0,1,4.7,3.8,14.66,14.66,0,0,1,2.4,6.4,56.16,56.16,0,0,1,.7,9.2c0,1.9.1,3.8.3,5.9a13.67,13.67,0,0,0,1.8,5.6h14.6c-1.5-1.6-2.5-4.3-3.2-8A67.06,67.06,0,0,1,671,64.9Zm-15.7-25c-2.2,2.1-5.6,3.1-9.9,3.1H623V18.6h22.1a29.22,29.22,0,0,1,5.1.4,11.39,11.39,0,0,1,4.4,1.8,9.52,9.52,0,0,1,3,3.6,13.64,13.64,0,0,1,1.1,6c0,4.3-1.1,7.4-3.4,9.5Z"/><polygon class="d" points="554.1 50.8 593.3 50.8 593.3 39.7 554.1 39.7 554.1 19.3 596.5 19.3 596.5 7.5 540.4 7.5 540.4 85.4 597.2 85.4 597.2 73.6 554.1 73.6 554.1 50.8"/><polygon class="d" points="503.2 67 503 67 487.7 7.5 473.8 7.5 458 67 457.8 67 443.8 7.5 429.9 7.5 450.4 85.4 464.5 85.4 480.4 25.8 480.6 25.8 496.2 85.4 510.1 85.4 531.5 7.5 517.7 7.5 503.2 67"/><path class="d" d="M416.6,17.8A35.07,35.07,0,0,0,404.9,9a38.76,38.76,0,0,0-31.3,0,35.07,35.07,0,0,0-11.7,8.8,38.19,38.19,0,0,0-7.4,13,49.91,49.91,0,0,0,0,31.5,38.19,38.19,0,0,0,7.4,13A33.51,33.51,0,0,0,373.6,84a39.58,39.58,0,0,0,31.3,0,35.07,35.07,0,0,0,11.7-8.8,38.19,38.19,0,0,0,7.4-13,49.91,49.91,0,0,0,0-31.5A38.71,38.71,0,0,0,416.6,17.8Zm-5,39.5a30,30,0,0,1-4.2,9.5,20.71,20.71,0,0,1-7.4,6.7,23.93,23.93,0,0,1-21.5,0,20.71,20.71,0,0,1-7.4-6.7,30,30,0,0,1-4.2-9.5,44.68,44.68,0,0,1,0-21.8,30,30,0,0,1,4.2-9.5,20.71,20.71,0,0,1,7.4-6.7,23.93,23.93,0,0,1,21.5,0,20.71,20.71,0,0,1,7.4,6.7,30,30,0,0,1,4.2,9.5,44.68,44.68,0,0,1,0,21.8Z"/><path class="d" d="M339.2,15.9a21,21,0,0,0-8.1-6q-5.25-2.4-13.5-2.4H283.2V85.4h13.6V55.5h20.7A34.49,34.49,0,0,0,331,53.2a21.73,21.73,0,0,0,8.1-6,20.48,20.48,0,0,0,3.9-7.8,29.29,29.29,0,0,0,1-7.8,35.62,35.62,0,0,0-1-7.9A19.58,19.58,0,0,0,339.2,15.9Zm-10,21.8a10,10,0,0,1-3.2,3.9,11.94,11.94,0,0,1-4.4,2.1,24.22,24.22,0,0,1-4.7.7h-20V18.6h20.2a29.37,29.37,0,0,1,5.1.5,10,10,0,0,1,4.3,2,9.62,9.62,0,0,1,2.9,4,15.25,15.25,0,0,1,1.1,6.3,13.72,13.72,0,0,1-1.3,6.3Z"/></svg></a>
        </li>

        <li class="logobox-three">
            <img class="logo-dyauto" src="http://client.1-2-3-4-5.studio/dy/sourcebox/dy_bg_test_03.png" style="background-size: cover; background-position: center center;">
            <a class="logo-dy-auto-link" href="http://client.1-2-3-4-5.studio/dy/dy-auto"><svg xmlns="http://www.w3.org/2000/svg" width="197.78mm" height="32.91mm" viewBox="0 0 560.64 93.28"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}.d{fill:#2ea7e0;}</style></defs><path class="a" d="M120.52,7.5H154c23.88,0,38.17,14.51,38.17,38.61,0,25.52-14.51,39.27-38.17,39.27H120.52ZM140.81,68h9.6c15.38-.33,21.48-6.33,21.48-21.93,0-14.18-7.63-21.05-21.48-21.05h-9.6Z"/><polygon class="a" points="241.69 7.5 226.2 39.13 210.72 7.5 187.7 7.5 216.06 56.36 216.06 85.38 236.35 85.38 236.35 56.36 264.71 7.5 241.69 7.5"/><path class="a" d="M14.3,93.28H58.66A31.24,31.24,0,0,0,89.9,62V17.77Z"/><polygon class="b" points="10.61 0 48.12 37.45 85.63 0 10.61 0"/><polygon class="c" points="0 85.76 37.46 48.26 0 10.75 0 85.76"/><path class="d" d="M550.67,17.75A35,35,0,0,0,539,9a39.08,39.08,0,0,0-31.3,0A34.93,34.93,0,0,0,496,17.78a39.35,39.35,0,0,0-7.36,13,49.53,49.53,0,0,0,0,31.51,39.35,39.35,0,0,0,7.36,13,34.43,34.43,0,0,0,11.72,8.78,39.75,39.75,0,0,0,31.3,0,34.56,34.56,0,0,0,11.72-8.78,39.35,39.35,0,0,0,7.36-13,49.81,49.81,0,0,0,0-31.51A39.34,39.34,0,0,0,550.67,17.75ZM545.6,57.34a30.3,30.3,0,0,1-4.2,9.54,21,21,0,0,1-7.36,6.7,24.21,24.21,0,0,1-21.48,0,21,21,0,0,1-7.36-6.7,30.3,30.3,0,0,1-4.2-9.54,44,44,0,0,1,0-21.81A30.08,30.08,0,0,1,505.2,26a21,21,0,0,1,7.36-6.71,24.21,24.21,0,0,1,21.48,0A20.94,20.94,0,0,1,541.4,26a30.08,30.08,0,0,1,4.2,9.54,44.48,44.48,0,0,1,0,21.81Z"/><polygon class="d" points="419.77 19.28 444.42 19.28 444.42 85.36 458.05 85.36 458.05 19.28 482.8 19.28 482.8 7.5 419.77 7.5 419.77 19.28"/><path class="d" d="M397.52,52.86q0,3.93-.38,8A18.33,18.33,0,0,1,395,68.11a14.09,14.09,0,0,1-5.46,5.29q-3.66,2.07-10.3,2.07T368.9,73.4a13.82,13.82,0,0,1-5.46-5.29,18.33,18.33,0,0,1-2.18-7.25c-.26-2.69-.38-5.35-.38-8V7.5H347.25V57.34a34.18,34.18,0,0,0,2.29,13.08A25,25,0,0,0,356,79.74a26.9,26.9,0,0,0,10.08,5.62,47.17,47.17,0,0,0,26.18,0,27.26,27.26,0,0,0,10.08-5.62,25,25,0,0,0,6.49-9.32,34.18,34.18,0,0,0,2.29-13.08V7.5H397.52Z"/><path class="d" d="M298.58,7.5,268.7,85.36h14.07l7.3-20.61h31.08l7.31,20.61h14.61l-30-77.86Zm-4.8,46.89L305.56,21h.33l11.66,33.48Z"/></svg></a>
        </li>

        <li class="logobox-four">
            <img class="logo-dyinno" src="http://client.1-2-3-4-5.studio/dy/sourcebox/dy_bg_test_04.png" style="background-size: cover; background-position: center center;">
            <a class="logo-dy-inno-link" href="http://client.1-2-3-4-5.studio/dy/dy-innovate"><svg xmlns="http://www.w3.org/2000/svg" width="282.74mm" height="32.91mm" viewBox="0 0 801.48 93.28"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}.d{fill:#2ea7e0;}</style></defs><path class="a" d="M120.52,7.51H154c23.88,0,38.17,14.5,38.17,38.61,0,25.52-14.51,39.26-38.17,39.26H120.52Zm20.29,60.42h9.6c15.38-.33,21.48-6.32,21.48-21.92,0-14.18-7.63-21-21.48-21h-9.6Z"/><polygon class="a" points="241.69 7.51 226.2 39.14 210.72 7.51 187.7 7.51 216.06 56.37 216.06 85.38 236.35 85.38 236.35 56.37 264.71 7.51 241.69 7.51"/><path class="a" d="M14.3,93.28H58.66A31.24,31.24,0,0,0,89.9,62V17.78Z"/><polygon class="b" points="10.61 0 48.12 37.46 85.63 0 10.61 0"/><polygon class="c" points="0 85.77 37.46 48.26 0 10.75 0 85.77"/><polygon class="d" points="758.3 73.59 758.3 50.8 797.56 50.8 797.56 39.68 758.3 39.68 758.3 19.29 800.72 19.29 800.72 7.51 744.67 7.51 744.67 85.37 801.48 85.37 801.48 73.59 758.3 73.59"/><polygon class="d" points="672.7 19.29 697.35 19.29 697.35 85.37 710.98 85.37 710.98 19.29 735.73 19.29 735.73 7.51 672.7 7.51 672.7 19.29"/><path class="d" d="M636.18,7.51,606.31,85.37h14.06l7.31-20.61h31.08l7.3,20.61h14.61l-30-77.86ZM631.39,54.4l11.77-33.48h.33L655.16,54.4Z"/><polygon class="d" points="598.35 7.51 578.39 69.12 578.17 69.12 558.65 7.51 544.48 7.51 570.43 85.37 585.59 85.37 612.19 7.51 598.35 7.51"/><path class="d" d="M533,17.76a35,35,0,0,0-11.73-8.83,39,39,0,0,0-31.29,0,34.93,34.93,0,0,0-11.72,8.83,39.1,39.1,0,0,0-7.37,13,49.81,49.81,0,0,0,0,31.51,39.38,39.38,0,0,0,7.37,13A34.24,34.24,0,0,0,490,84a39.65,39.65,0,0,0,31.29,0A34.55,34.55,0,0,0,533,75.28a39.45,39.45,0,0,0,7.36-13,49.81,49.81,0,0,0,0-31.51A39.4,39.4,0,0,0,533,17.76Zm-5.07,39.58a30.3,30.3,0,0,1-4.2,9.54,21.15,21.15,0,0,1-7.36,6.71,24.23,24.23,0,0,1-21.49,0,21.15,21.15,0,0,1-7.36-6.71,30.05,30.05,0,0,1-4.19-9.54,44,44,0,0,1,0-21.81A30.05,30.05,0,0,1,487.52,26a21,21,0,0,1,7.36-6.7,24.23,24.23,0,0,1,21.49,0,21,21,0,0,1,7.36,6.7,30.3,30.3,0,0,1,4.2,9.54A44.48,44.48,0,0,1,527.93,57.34Z"/><polygon class="d" points="442.87 64.87 442.65 64.87 407.1 7.51 392.71 7.51 392.71 85.37 405.69 85.37 405.69 28.12 406.01 28.12 441.45 85.37 455.85 85.37 455.85 7.51 442.87 7.51 442.87 64.87"/><polygon class="d" points="363.49 64.87 363.27 64.87 327.72 7.51 313.33 7.51 313.33 85.37 326.31 85.37 326.31 28.12 326.63 28.12 362.07 85.37 376.47 85.37 376.47 7.51 363.49 7.51 363.49 64.87"/><rect class="d" x="283.26" y="7.51" width="13.63" height="77.86"/></svg></a>
        </li>
    </ul>
</div>

main page(home)

title: DY
columns:
  - width: 1/1
    sections:
      pages:
        type: pages
        create: false
        templates:
          - dy
          - dyauto
          - dypower
          - dyinno

  - width: 1/1
    sections:
      albums: sections/albums

  - width: 1/1
    sections:
      autoalbums: sections/autoalbums

  - width: 1/1
    sections:
      poweralbums: sections/poweralbums

  - width: 1/1
    sections:
      innoalbums: sections/innoalbums

Hm, I’m a bit confused. Because your logos seem to be added manually but then your are obviously trying to get images from the children of the photography page, but from some reason the number of images and the number of logos do not align.

The loop through the children of the photography page doesn’t seem to make sense and I don’t really understand how they relate to the logos.

1 Like

Each of the 4 logos should have one background image. It’s too hard for me…
I changed the image registered on each page to the main page, but ‘DY’ succeeded in importing the image, but the other three couldn’t even bring the image even if I entered the same code.
http://client.1-2-3-4-5.studio/dy/kr

home.php

<div class="logobox-set">
    <ul class="logobox">
        <li class="logobox-one">
          <?php if ($dypage = page('dy')): ?>
          <?php if($bgimage = $dypage->dycovers()->toFile()): ?>
            <img class="logo-dy" src="<?= $bgimage->url()?>" style="background-size: cover; background-position: center center;">
          <?php endif ?>
          <?php endif ?>
            <a class="logo-dy-link" href="http://client.1-2-3-4-5.studio/dy/dy">
                <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 264.71 93.28"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}</style></defs><path class="a" d="M120.52,7.51H154c23.88,0,38.17,14.5,38.17,38.6,0,25.53-14.51,39.27-38.17,39.27H120.52Zm20.29,60.42h9.6c15.38-.33,21.48-6.33,21.48-21.92,0-14.18-7.63-21-21.48-21h-9.6Z"/><polygon class="a" points="241.69 7.5 226.2 39.13 210.72 7.5 187.7 7.5 216.06 56.37 216.06 85.38 236.35 85.38 236.35 56.37 264.71 7.5 241.69 7.5"/><path class="a" d="M14.3,93.28H58.66A31.24,31.24,0,0,0,89.9,62V17.77Z"/><polygon class="b" points="10.61 0 48.12 37.46 85.63 0 10.61 0"/><polygon class="c" points="0 85.77 37.46 48.26 0 10.75 0 85.77"/></svg>
            </a>
        </li>


        <li class="logobox-two">
          <?php if ($powerpage = page('dypower')): ?>
          <?php if($bgimage = $powerpage->dypowercovers()->toFile()): ?>
            <img class="logo-dypower" src="<?= $bgimage->url()?>" style="background-size: cover; background-position: center center;">
          <?php endif ?>
          <?php endif ?>
            <a class="logo-dy-power-link" href="http://client.1-2-3-4-5.studio/dy/dy-power"><svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 675.3 93.3"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}.d{fill:#2ea7e0;}</style></defs><path class="a" d="M120.5,7.5H154c23.9,0,38.2,14.5,38.2,38.6,0,25.5-14.5,39.3-38.2,39.3H120.5Zm20.3,60.4h9.6c15.4-.3,21.5-6.3,21.5-21.9,0-14.2-7.6-21-21.5-21h-9.6Z"/><polygon class="a" points="241.7 7.5 226.2 39.1 210.7 7.5 187.7 7.5 216.1 56.4 216.1 85.4 236.4 85.4 236.4 56.4 264.7 7.5 241.7 7.5"/><path class="a" d="M14.3,93.3H58.7A31.18,31.18,0,0,0,89.9,62.1h0V17.8Z"/><polygon class="b" points="10.6 0 48.1 37.5 85.6 0 10.6 0"/><polygon class="c" points="0 85.8 37.5 48.3 0 10.8 0 85.8"/><path class="d" d="M671,64.9a19.56,19.56,0,0,0-1.2-7.6,14.87,14.87,0,0,0-2.9-5,10.75,10.75,0,0,0-3.8-2.8,16.57,16.57,0,0,0-3.8-1.1v-.2c.7-.2,1.7-.7,3.1-1.3a15.09,15.09,0,0,0,4.3-3.2,19.27,19.27,0,0,0,3.8-5.9,22.35,22.35,0,0,0,1.6-9.2c0-6.6-2.1-11.8-6.4-15.5S655,7.5,646.4,7.5H609.2V85.4H623v-32h20.1a20.36,20.36,0,0,1,7.7,1.2,9.75,9.75,0,0,1,4.7,3.8,14.66,14.66,0,0,1,2.4,6.4,56.16,56.16,0,0,1,.7,9.2c0,1.9.1,3.8.3,5.9a13.67,13.67,0,0,0,1.8,5.6h14.6c-1.5-1.6-2.5-4.3-3.2-8A67.06,67.06,0,0,1,671,64.9Zm-15.7-25c-2.2,2.1-5.6,3.1-9.9,3.1H623V18.6h22.1a29.22,29.22,0,0,1,5.1.4,11.39,11.39,0,0,1,4.4,1.8,9.52,9.52,0,0,1,3,3.6,13.64,13.64,0,0,1,1.1,6c0,4.3-1.1,7.4-3.4,9.5Z"/><polygon class="d" points="554.1 50.8 593.3 50.8 593.3 39.7 554.1 39.7 554.1 19.3 596.5 19.3 596.5 7.5 540.4 7.5 540.4 85.4 597.2 85.4 597.2 73.6 554.1 73.6 554.1 50.8"/><polygon class="d" points="503.2 67 503 67 487.7 7.5 473.8 7.5 458 67 457.8 67 443.8 7.5 429.9 7.5 450.4 85.4 464.5 85.4 480.4 25.8 480.6 25.8 496.2 85.4 510.1 85.4 531.5 7.5 517.7 7.5 503.2 67"/><path class="d" d="M416.6,17.8A35.07,35.07,0,0,0,404.9,9a38.76,38.76,0,0,0-31.3,0,35.07,35.07,0,0,0-11.7,8.8,38.19,38.19,0,0,0-7.4,13,49.91,49.91,0,0,0,0,31.5,38.19,38.19,0,0,0,7.4,13A33.51,33.51,0,0,0,373.6,84a39.58,39.58,0,0,0,31.3,0,35.07,35.07,0,0,0,11.7-8.8,38.19,38.19,0,0,0,7.4-13,49.91,49.91,0,0,0,0-31.5A38.71,38.71,0,0,0,416.6,17.8Zm-5,39.5a30,30,0,0,1-4.2,9.5,20.71,20.71,0,0,1-7.4,6.7,23.93,23.93,0,0,1-21.5,0,20.71,20.71,0,0,1-7.4-6.7,30,30,0,0,1-4.2-9.5,44.68,44.68,0,0,1,0-21.8,30,30,0,0,1,4.2-9.5,20.71,20.71,0,0,1,7.4-6.7,23.93,23.93,0,0,1,21.5,0,20.71,20.71,0,0,1,7.4,6.7,30,30,0,0,1,4.2,9.5,44.68,44.68,0,0,1,0,21.8Z"/><path class="d" d="M339.2,15.9a21,21,0,0,0-8.1-6q-5.25-2.4-13.5-2.4H283.2V85.4h13.6V55.5h20.7A34.49,34.49,0,0,0,331,53.2a21.73,21.73,0,0,0,8.1-6,20.48,20.48,0,0,0,3.9-7.8,29.29,29.29,0,0,0,1-7.8,35.62,35.62,0,0,0-1-7.9A19.58,19.58,0,0,0,339.2,15.9Zm-10,21.8a10,10,0,0,1-3.2,3.9,11.94,11.94,0,0,1-4.4,2.1,24.22,24.22,0,0,1-4.7.7h-20V18.6h20.2a29.37,29.37,0,0,1,5.1.5,10,10,0,0,1,4.3,2,9.62,9.62,0,0,1,2.9,4,15.25,15.25,0,0,1,1.1,6.3,13.72,13.72,0,0,1-1.3,6.3Z"/></svg></a>
        </li>




        <li class="logobox-three">
          <?php if ($dyautopage = page('dyauto')): ?>
          <?php if($bgimage = $dyautopage->dyautocovers()->toFile()): ?>
            <img class="logo-dyauto" src="<?= $bgimage->url()?>" style="background-size: cover; background-position: center center;">
            <?php endif ?>
            <?php endif ?>
            <a class="logo-dy-auto-link" href="http://client.1-2-3-4-5.studio/dy/dy-auto"><svg xmlns="http://www.w3.org/2000/svg" width="197.78mm" height="32.91mm" viewBox="0 0 560.64 93.28"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}.d{fill:#2ea7e0;}</style></defs><path class="a" d="M120.52,7.5H154c23.88,0,38.17,14.51,38.17,38.61,0,25.52-14.51,39.27-38.17,39.27H120.52ZM140.81,68h9.6c15.38-.33,21.48-6.33,21.48-21.93,0-14.18-7.63-21.05-21.48-21.05h-9.6Z"/><polygon class="a" points="241.69 7.5 226.2 39.13 210.72 7.5 187.7 7.5 216.06 56.36 216.06 85.38 236.35 85.38 236.35 56.36 264.71 7.5 241.69 7.5"/><path class="a" d="M14.3,93.28H58.66A31.24,31.24,0,0,0,89.9,62V17.77Z"/><polygon class="b" points="10.61 0 48.12 37.45 85.63 0 10.61 0"/><polygon class="c" points="0 85.76 37.46 48.26 0 10.75 0 85.76"/><path class="d" d="M550.67,17.75A35,35,0,0,0,539,9a39.08,39.08,0,0,0-31.3,0A34.93,34.93,0,0,0,496,17.78a39.35,39.35,0,0,0-7.36,13,49.53,49.53,0,0,0,0,31.51,39.35,39.35,0,0,0,7.36,13,34.43,34.43,0,0,0,11.72,8.78,39.75,39.75,0,0,0,31.3,0,34.56,34.56,0,0,0,11.72-8.78,39.35,39.35,0,0,0,7.36-13,49.81,49.81,0,0,0,0-31.51A39.34,39.34,0,0,0,550.67,17.75ZM545.6,57.34a30.3,30.3,0,0,1-4.2,9.54,21,21,0,0,1-7.36,6.7,24.21,24.21,0,0,1-21.48,0,21,21,0,0,1-7.36-6.7,30.3,30.3,0,0,1-4.2-9.54,44,44,0,0,1,0-21.81A30.08,30.08,0,0,1,505.2,26a21,21,0,0,1,7.36-6.71,24.21,24.21,0,0,1,21.48,0A20.94,20.94,0,0,1,541.4,26a30.08,30.08,0,0,1,4.2,9.54,44.48,44.48,0,0,1,0,21.81Z"/><polygon class="d" points="419.77 19.28 444.42 19.28 444.42 85.36 458.05 85.36 458.05 19.28 482.8 19.28 482.8 7.5 419.77 7.5 419.77 19.28"/><path class="d" d="M397.52,52.86q0,3.93-.38,8A18.33,18.33,0,0,1,395,68.11a14.09,14.09,0,0,1-5.46,5.29q-3.66,2.07-10.3,2.07T368.9,73.4a13.82,13.82,0,0,1-5.46-5.29,18.33,18.33,0,0,1-2.18-7.25c-.26-2.69-.38-5.35-.38-8V7.5H347.25V57.34a34.18,34.18,0,0,0,2.29,13.08A25,25,0,0,0,356,79.74a26.9,26.9,0,0,0,10.08,5.62,47.17,47.17,0,0,0,26.18,0,27.26,27.26,0,0,0,10.08-5.62,25,25,0,0,0,6.49-9.32,34.18,34.18,0,0,0,2.29-13.08V7.5H397.52Z"/><path class="d" d="M298.58,7.5,268.7,85.36h14.07l7.3-20.61h31.08l7.31,20.61h14.61l-30-77.86Zm-4.8,46.89L305.56,21h.33l11.66,33.48Z"/></svg></a>
        </li>

        <li class="logobox-four">
            <img class="logo-dyinno" src="http://client.1-2-3-4-5.studio/dy/sourcebox/dy_bg_test_04.png" style="background-size: cover; background-position: center center;">
            <a class="logo-dy-inno-link" href="http://client.1-2-3-4-5.studio/dy/dy-innovate"><svg xmlns="http://www.w3.org/2000/svg" width="282.74mm" height="32.91mm" viewBox="0 0 801.48 93.28"><defs><style>.a{fill:#073773;}.b{fill:#29aae2;}.c{fill:#006aac;}.d{fill:#2ea7e0;}</style></defs><path class="a" d="M120.52,7.51H154c23.88,0,38.17,14.5,38.17,38.61,0,25.52-14.51,39.26-38.17,39.26H120.52Zm20.29,60.42h9.6c15.38-.33,21.48-6.32,21.48-21.92,0-14.18-7.63-21-21.48-21h-9.6Z"/><polygon class="a" points="241.69 7.51 226.2 39.14 210.72 7.51 187.7 7.51 216.06 56.37 216.06 85.38 236.35 85.38 236.35 56.37 264.71 7.51 241.69 7.51"/><path class="a" d="M14.3,93.28H58.66A31.24,31.24,0,0,0,89.9,62V17.78Z"/><polygon class="b" points="10.61 0 48.12 37.46 85.63 0 10.61 0"/><polygon class="c" points="0 85.77 37.46 48.26 0 10.75 0 85.77"/><polygon class="d" points="758.3 73.59 758.3 50.8 797.56 50.8 797.56 39.68 758.3 39.68 758.3 19.29 800.72 19.29 800.72 7.51 744.67 7.51 744.67 85.37 801.48 85.37 801.48 73.59 758.3 73.59"/><polygon class="d" points="672.7 19.29 697.35 19.29 697.35 85.37 710.98 85.37 710.98 19.29 735.73 19.29 735.73 7.51 672.7 7.51 672.7 19.29"/><path class="d" d="M636.18,7.51,606.31,85.37h14.06l7.31-20.61h31.08l7.3,20.61h14.61l-30-77.86ZM631.39,54.4l11.77-33.48h.33L655.16,54.4Z"/><polygon class="d" points="598.35 7.51 578.39 69.12 578.17 69.12 558.65 7.51 544.48 7.51 570.43 85.37 585.59 85.37 612.19 7.51 598.35 7.51"/><path class="d" d="M533,17.76a35,35,0,0,0-11.73-8.83,39,39,0,0,0-31.29,0,34.93,34.93,0,0,0-11.72,8.83,39.1,39.1,0,0,0-7.37,13,49.81,49.81,0,0,0,0,31.51,39.38,39.38,0,0,0,7.37,13A34.24,34.24,0,0,0,490,84a39.65,39.65,0,0,0,31.29,0A34.55,34.55,0,0,0,533,75.28a39.45,39.45,0,0,0,7.36-13,49.81,49.81,0,0,0,0-31.51A39.4,39.4,0,0,0,533,17.76Zm-5.07,39.58a30.3,30.3,0,0,1-4.2,9.54,21.15,21.15,0,0,1-7.36,6.71,24.23,24.23,0,0,1-21.49,0,21.15,21.15,0,0,1-7.36-6.71,30.05,30.05,0,0,1-4.19-9.54,44,44,0,0,1,0-21.81A30.05,30.05,0,0,1,487.52,26a21,21,0,0,1,7.36-6.7,24.23,24.23,0,0,1,21.49,0,21,21,0,0,1,7.36,6.7,30.3,30.3,0,0,1,4.2,9.54A44.48,44.48,0,0,1,527.93,57.34Z"/><polygon class="d" points="442.87 64.87 442.65 64.87 407.1 7.51 392.71 7.51 392.71 85.37 405.69 85.37 405.69 28.12 406.01 28.12 441.45 85.37 455.85 85.37 455.85 7.51 442.87 7.51 442.87 64.87"/><polygon class="d" points="363.49 64.87 363.27 64.87 327.72 7.51 313.33 7.51 313.33 85.37 326.31 85.37 326.31 28.12 326.63 28.12 362.07 85.37 376.47 85.37 376.47 7.51 363.49 7.51 363.49 64.87"/><rect class="d" x="283.26" y="7.51" width="13.63" height="77.86"/></svg></a>
        </li>
    </ul>
</div>

models/home.php

<?php
class HomePage extends Page
{

	public function bgimage()
    {
        return $this->content()->get('bgimage')->toFile() ?? $this->image();
    }

    public function cover()
    {
        return $this->content()->get('cover')->toFile() ?? $this->image();
    }

    public function covers()
    {
        return $this->content()->cover()->toFile() ?? $this->image();
    }

    public function dycovers()
    {
        return $this->content()->get('dycovers')->toFile() ?? $this->image();
    }

    public function dypowercovers()
    {
        return $this->content()->get('dypowercovers')->toFile() ?? $this->image();
    }

    public function dyautocovers()
    {
        return $this->content()->get('dyautocovers')->toFile() ?? $this->image();
    }

    public function dyinnocovers()
    {
        return $this->content()->get('dyinnocovers')->toFile() ?? $this->image();
    }

    public function published($format = null)
    {
        return parent::date()->toDate($format ?? 'd M, Y');
    }
}

models/dy.php

<?php
class dyPage extends Page
{

	public function bgimage()
    {
        return $this->content()->get('bgimage')->toFile() ?? $this->image();
    }

    public function cover()
    {
        return $this->content()->get('cover')->toFile() ?? $this->image();
    }

    public function covers()
    {
        return $this->content()->cover()->toFile() ?? $this->image();
    }

    public function published($format = null)
    {
        return parent::date()->toDate($format ?? 'd M, Y');
    }
}

models/dyauto.php

<?php
class dyautoPage extends Page
{

	public function bgimage()
    {
        return $this->content()->get('bgimage')->toFile() ?? $this->image();
    }

    public function cover()
    {
        return $this->content()->get('cover')->toFile() ?? $this->image();
    }

    public function covers()
    {
        return $this->content()->cover()->toFile() ?? $this->image();
    }

    public function published($format = null)
    {
        return parent::date()->toDate($format ?? 'd M, Y');
    }
}

dy.yml

title: DY

icon: 📝

status:
  draft: true
  unlisted:
    label: Hidden Page
    text: The page is not listed in the main menu
  listed:
    label: Menu Page
    text: The page is listed in the main menu

tabs:
  tab1:
    label: 메뉴 관리
    preset: pages

  toptitlebox:
    label: 메인 이미지
    icon: text
    columns:
      - width: 1/1
        fields:
          dycovers:
            label: 데스크톱 표지
            type: files
            layout: cards
            template: image
            info: "{{ file.dimensions }}"
            uploads: false
            image:
              ratio: 5/4
              cover: true
            size: small
            help: 가로형 사진을 선택합니다.

          dymobilecovers:
            label: 모바일 표지
            type: files
            layout: cards
            template: image
            info: "{{ file.dimensions }}"
            uploads: false
            image:
              ratio: 5/4
              cover: true
            size: small
            help: 세로형 사진을 선택합니다.

      - width: 1/1
        sections:
          allfiles:
            headline: 이미지 아카이브
            type: files
            layout: cards
            # template: image
            info: "{{ file.dimensions }}"
            image:
              ratio: 5/4
              cover: true
            size: small
            help: 최대 1600px 이하 크기 이미지로 업로드 권장, 파일명 영문 소문자, 언더바, 숫자만 사용.

  toplinkbox:
    label: 외부 링크 관리
    icon: text
    columns:
      - width: 1/1
        fields:
          newslink:
            label: 전자사보
            type: text

dyauto.yml

title: DY AUTO

icon: 📝

status:
  draft: true
  unlisted:
    label: Hidden Page
    text: The page is not listed in the main menu
  listed:
    label: Menu Page
    text: The page is listed in the main menu

tabs:
  tab1:
    label: 메뉴 관리
    preset: pages

  toptitlebox:
    label: 메인 이미지
    icon: text
    columns:
      - width: 1/1
        fields:
          dyautocovers:
            label: 데스크톱 표지
            type: files
            layout: cards
            template: image
            info: "{{ file.dimensions }}"
            uploads: false
            image:
              ratio: 5/4
              cover: true
            size: small
            help: 가로형 사진을 선택합니다.

          dyautomobilecovers:
            label: 모바일 표지
            type: files
            layout: cards
            template: image
            info: "{{ file.dimensions }}"
            uploads: false
            image:
              ratio: 5/4
              cover: true
            size: small
            help: 세로형 사진을 선택합니다.지


      - width: 1/1
        sections:
          allfiles:
            headline: 이미지 아카이브
            type: files
            layout: cards
            # template: image
            info: "{{ file.dimensions }}"
            image:
              ratio: 5/4
              cover: true
            size: small
            help: 최대 1600px 이하 크기 이미지로 업로드 권장, 파일명 영문 소문자, 언더바, 숫자만 사용

I’ve solved that problem! Thank you!