Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 UTC on 18 March 2024, to get $100 off your ticket.
Problem
Fields without a value get rendered in D8 head (as of 26.4.2015). The field label for the empty field get rendered to.
Expected Behavior
Empty fields dont get rendered, especially not their labels. Thats the way it used to be in D7. And as I remember in early betas of D8.
Steps to reproduce
- Create a new content type.
- Add a textfield with a label.
- Add a new node of the new content type.
- Just give it a title, leave everything else empty.
- View the node, look at the html.
Strange enough: the body field gets treated different.
Node content:
Node display:
Node markup:
Comment | File | Size | Author |
---|---|---|---|
Bildschirmfoto 2015-04-26 um 10.41.16.png | 58.74 KB | derheap | |
Bildschirmfoto 2015-04-26 um 10.40.11.png | 25.33 KB | derheap | |
Bildschirmfoto 2015-04-26 um 10.40.01.png | 43.85 KB | derheap |
Comments
Comment #1
derheap CreditAttribution: derheap commentedComment #2
derheap CreditAttribution: derheap commentedComment #3
yched CreditAttribution: yched commentedThat's a bug in the 'string' field type: #2349819: String field type doesn't consider empty string as empty value