I’ve created a Virtual Gallery plugin using the steps found in the tutorial here: Virtual pages from image gallery | Kirby CMS (getkirby.com).
There seems to be a slight bug, whereby anything I enter into the Title field will get saved and be reflected in the site’s front-end, but opening the image details again shows a blank field. I’ve copied the code exactly so I’m not sure what could be going wrong. Any ideas?
Hm, I can’t get it to work at all in a 3.6.x Starterkit, while I don’t have issues in the old version in which I created it originally.
Will look into it tonight.
Which Kirby version are you using?
I’m on 3.6.2. Thanks for looking into it!
Hm, I now tested with a fresh 3.6.4 Starterkit and cannot reproduce your issue.
But I’m running into an issue with the file component that I had to disable, otherwise the files don’t show up in the Panel at all for me and addtionally I’m getting a Bad Gateway and The Json response couldn’t be parsed error.
Just a thought - could this be a PHP version issue? I’m running 8.0.2 on my webhost.
Are you only getting this issue on the remote server?
Also on my local machine, running 8.0.
Hm, does this only happen with the title or other fields as well. As I wrote, I cannot reproduce the issue with the disappearing title, but tested with a newer Kirby version.
Just with the title, oddly. I have an alt text field and a description, both of which work fine.
I stripped the other fields (photographer, date etc.) out of the template as I’m not using them in my implementation.
And if you rename the title field to something else and change the model accordingly?
For some reason, that hadn’t occurred to me! Changing
title to something like
displayTitle fixes the issue. Thanks!
EDIT: It’s not a PHP version issue, at least not with Kirby 3.6.2 - switching my development host to PHP 7.4.21 doesn’t seem to make a difference. The
title field still gets ‘lost’ in the panel.