Hi everybody,
so I added a structure table to my template in Kirby, where I want to insert links and names for the links. On my website I just want to show a certain name instead of the link, which you can type in my table as well.
so this is how my blueprint looks like
links:
label: Nur für die Links
type: structure
style: table
entry: >
{{linkName}}
{{link}}
fields:
linkName:
label: Titel
type: text
link:
label: Links
type: url
and this is my foreach loop
when i look on my website, it does get the actual link, but not the linkName. It gives the message ‘Illegal string offset’linkName’…’
Does anybody has an idea to solve this or know what I did wrong ?
Try the lowercased variant in your template: linkname.
Also, the entry blueprint option is currently not compatible with the table style, so it currently won’t do anything. But that’s unrelated to your issue.
Woah. The weirdest thing ever just happened. I randomly discovered that you can click and drag the bold text in those warning messages like you see in Mia’s screenshot. You can grab the Warning and the file/path/to/stuff and the line number. So I was idly dragging them a short distance and letting go and they would snap back. Then I dragged on of the line numbers all the way underneath the spot where the list of entries should be (like underneath the table in Mia’s screenshot), and then THE PROBLEM DISAPPEARED! The page works now!
?!?!?!
I’m going to go to bed now and see if this is still real when I wake up in the morning…
Yeah, well I think that the messed up txt file is because I was trying to save the page in the Kirby panel and it wasn’t working. Originally and eventually it looked like you said with the related pages separated by -.
By the way, I am generating pages with a script to transfer an old site into Kirby, but since the bizarre incident I described I haven’t had these errors anymore.