# Strange structure behaviour in 2.3.2

**URL:** <https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542>\
**Category:** Questions\
**Tags:** v2\
**Created:** [October 18, 2016, 11:52am UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542 "2016-10-18T11:52:07Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 18, 2016, 11:52am UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/1 "2016-10-18T11:52:08Z")

</div>

Hello,

i have experienced some strange behaviour while adding structure field entries in panel:

- i have 2 languages “de”(default) and “en”.

- i create a page and some structure field elements.

- after saving and switching the language to “en” i see the structure entries.

- going back to “de”

- adding another structure field element.

- save

- switch to “en”

- added entry not visible in “en” !?

- deleting all structure entrys in “en” view

- hit save

- all entries from “de” (the default language) are back again (as expected)

maybe it is a cache problem?

S.

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 18, 2016, 12:06pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/2 "2016-10-18T12:06:17Z")

</div>

Yes, this is most likely cache related, I can reproduce this. Will check with 2.4.0 beta.

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 18, 2016, 12:28pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/3 "2016-10-18T12:28:00Z")

</div>

I have [created an issue on GitHub](https://github.com/getkirby/panel/issues/936).

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 18, 2016, 12:29pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/4 "2016-10-18T12:29:27Z")

</div>

Thank you! 💟

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 11:16am UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/5 "2016-10-19T11:16:36Z")

</div>

I also found some glitches with “untranslated” fields.

If i iopen up a structure entry in the non default language for the first time it looks like this:

 ![](https://europe1.discourse-cdn.com/flex017/uploads/getkirby/original/2X/a/a4794f54433b4e7c8f0b295c7cd320999c98443b.png)

After saving it and reopening it looks like this:

 ![](https://europe1.discourse-cdn.com/flex017/uploads/getkirby/original/2X/5/5ae463019446314e712b01260743f0cd30ed86ab.png)

The untranslated settings are gone… why?

How can i get a structure element in a template in a non default language filled up with the untranslated/global values from the default language?

E.g. i am in a "en"glish view, “de” is the default and there are some fields with the “translate:false” setting. This fields should be “merged” to the “en” page object? How?

best Regards,  
Sven

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 19, 2016, 11:26am UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/6 "2016-10-19T11:26:46Z")

</div>

Hm, I can’t reproduce this. Could you please post your blueprint for testing? And maybe a step by step instruction on how to reproduce this?

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 11:28am UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/7 "2016-10-19T11:28:34Z")

</div>

Sure. Here it is:

```
title: Formular
pages: true
files: true
fields:
  title:
    label: Title
    type: text
  text:
    label: Text
    type: textarea

  ffields:
    label: Formular
    type: structure
    #style: table
    modalsize: large
    entry: >
      <u><b>{{_fieldtype}}&nbsp&nbsp</b></u>&nbsp;&nbsp;&nbsp;Name: <i>{{_fieldname}}</i>&nbsp;&nbsp;&nbsp;ID: <b>{{_fieldid}}</b> 
    fields:
      _fieldtype:
        width: 1/3
        required: true
        translate: false
        label:
          de: Eingabetyp
          en: Field type
        type: select
        options:
          _text: Text
          _textarea: Textarea
          _radio: Radio
          _check: Checkbox
          _select: Selectbox
          _submit: Submit button
          _layout: Layout
          _info: Info text
      _fieldname:
        width: 1/3
        label:
          de: Feldname
          en: Field name 
        type: text
      _fieldid:
        width: 1/3
        label:
          de: Feld-ID
          en: Field id
        type: text
        translate: false
      _visibility:
        label:
          de: Sichtbarkeit
          en: Visibility
        type: checkboxes
        translate: false
        width: 2/3
        #default: _visible
        options:
          _visible:
            de: Unsichtbar
            en: Invisible
      _fieldmeta:
        label:
          de: Feld Meta Daten
          en: Field meta data
        type: textarea

```

- create a entry in default language
- save
- change to non default language
- open the entry
- save
- open again  
-\> non translated values are gone

It doesn’t matter whether is saved to the non default languages untranslateble fields… on the template i need a “merged” version for the selected language… the data from the default language merged/partly overwritten with the current selected language. How can i do this programmatically?

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 19, 2016, 11:50am UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/8 "2016-10-19T11:50:31Z")

</div>

I’ll try to look into this asap. My first test did not even show the entry in the English view …😕

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 11:52am UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/9 "2016-10-19T11:52:23Z")

</div>

Yes, this is the problem i reported above.

Thank you!

Here is a screen recording of the issue:

 ![](https://europe1.discourse-cdn.com/flex017/uploads/getkirby/original/2X/a/a628a2f8d259c487e30e643dc1b95262ece25fd6.gif)

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 19, 2016, 2:22pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/10 "2016-10-19T14:22:35Z")

</div>

I have created [another issue on GitHub](https://github.com/getkirby/panel/issues/937). Unfortunately, I can’t test this in Kirby 2.4.0 beta because of another issue.

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 2:28pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/11 "2016-10-19T14:28:05Z")

</div>

Thank you!

I hope it is fixable soon because my project(s) rely heavily on the structure and translation features.

best regards,  
Sven

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 19, 2016, 2:31pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/12 "2016-10-19T14:31:17Z")

</div>

It just seems strange that this issue hasn’t surfaced earlier. Did it work in a previous version of Kirby?

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 2:34pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/13 "2016-10-19T14:34:44Z")

</div>

I don’t know. In what version the “translate:false” blueprint option was introduced?  
Where can i get this old versions starterKit?

S.

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 19, 2016, 2:37pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/14 "2016-10-19T14:37:38Z")

</div>

Maybe the behaviour is intentional after all:

> Since Kirby 2.2.3, the contents of an untranslatable field will be emptied in all languages but the default language.

[https://getkirby.com/docs/panel/blueprints/form-fields#prevent-field-values-in-non-default-languages](https://getkirby.com/docs/panel/blueprints/form-fields#prevent-field-values-in-non-default-languages)

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 2:51pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/15 "2016-10-19T14:51:32Z")

</div>

Hm, it seems so.

But how can i “merge” the data on a template?

S.

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 19, 2016, 2:53pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/16 "2016-10-19T14:53:37Z")

</div>

That should be automatic, as Kirby falls back to the default language if the value of the non-default language is empty.

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 3:13pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/17 "2016-10-19T15:13:37Z")

</div>

Should but want do it here. I get NULL for all untranslateble fields:

`<?php $ffields = yaml($page->ffields());var_dump($ffields); ?>`

gives me:

```
  [6]=>
  array(5) {
    ["_fieldtype"]=>
    NULL
    ["_fieldname"]=>
    string(8) "Das Info"
    ["_fieldid"]=>
    NULL
    ["_visibility"]=>
    NULL
    ["_fieldmeta"]=>
    string(22) "Das ist ein Info Text."
  }
  [7]=>
  array(5) {
    ["_fieldtype"]=>
    NULL
    ["_fieldname"]=>
    string(4) "Send"
    ["_fieldid"]=>
    NULL
    ["_visibility"]=>
    NULL
    ["_fieldmeta"]=>
    string(0) ""
  }

```

Also the invisibility of untranslateble values from default language in the panel looks very strange. it would be nice if the grayed out fields display the values from the default language even if they will be emptied at save.

---

<div class="post-metadata">

**Author:** ![lukasbestle](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/lukasbestle/32/11437_2.png) [@lukasbestle](https://forum.getkirby.com/u/lukasbestle)\
**Post date:** [October 19, 2016, 3:14pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/18 "2016-10-19T15:14:46Z")

</div>

As far as I know, content is not inherited inside structure fields. Only the whole field is inherited if it’s completely empty. So this is indeed a bug.

---

<div class="post-metadata">

**Author:** ![Svnt](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/svnt/32/620_2.png) [@Svnt](https://forum.getkirby.com/u/Svnt)\
**Post date:** [October 19, 2016, 4:13pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/19 "2016-10-19T16:13:17Z")

</div>

Inheriting the whole field only if the field is completely empty makes no sense at all. ☹

---

<div class="post-metadata">

**Author:** ![texnixe](https://dub1.discourse-cdn.com/flex017/user_avatar/forum.getkirby.com/texnixe/32/5754_2.png) [@texnixe](https://forum.getkirby.com/u/texnixe)\
**Post date:** [October 19, 2016, 4:14pm UTC](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542/20 "2016-10-19T16:14:52Z")

</div>

Yes, I agree with you.

[Next page](https://forum.getkirby.com/t/strange-structure-behaviour-in-2-3-2/5542.md?page=2)
