Skip to content
Grav 2.0 is officially stable. Read the announcement →
Archive

Error on upload on page blueprint

Started by Muut Archive 9 years ago · 1 replies · 435 views
9 years ago

I have updated to the last version of Grav (1.2). But no it come an error when i try to uploade an image in a page.

Error message

My blueprint

YAML
title: start

form:
  fields:
    tabs:
      type: tabs
      active: 1

      fields:
        inhalt:
          type: tab
          title: Inhalt

          fields:
            header.start_desc: 
              type: editor
              label: Beschreibung
              validate:
                required: true
        start:
          type: tab
          title: Header
          fields:
            header.header_img:
              label: Bild
              type: file
              destination: 'user/pages/images/'
              multiple: false
              random_name: true
              accept:
                - image/*

            header.header_text:
              type: textarea
              label: Kurzer Slogan
              validate:
                required: true
                type: text

        options:
          type: tab
          title: Optionen

          fields:
            route:
              type: select
              label: PLUGIN_ADMIN.PARENT
              classes: fancy
              '@data-options': '\Grav\Common\Page\Pages::parents'
              '@data-default': '\Grav\Plugin\admin::route'
              options:
                '/': PLUGIN_ADMIN.DEFAULT_OPTION_ROOT
            header.visible:
              type: toggle
              label: Sichtbarkeit
              highlight: 1
              options:
                1: Sichtbar
                0: Versteckt
              validate:
                type: bool

in version 1.17 it was working fine.

9 years ago

I tested and I don't see any issue with Grav v1.2.0 - Admin v1.3.1.

Make sure the cache is disabled after changing the blueprint, or clear it.

That error comes when the file field does not have a destination property, but yours has it.

Suggested topics

Topic Participants Replies Views Activity
Archive · by Deleted User, 9 years ago
0 1327 9 years ago
Archive · by Muut Archive, 9 years ago
2 921 9 years ago
Archive · by Muut Archive, 9 years ago
2 4050 9 years ago
Archive · by Muut Archive, 9 years ago
1 2928 9 years ago
Archive · by Muut Archive, 9 years ago
3 1107 9 years ago