den
November 27, 2024, 7:41am
1
I’m trying to put a website from a local server (nginx) to my server (apache).
I have added a custom panel menu item in my config.php to a specific page used to store websites images :
...
'panel' => [
'menu' => fn() => [
'site' => Menu::site(),
'-',
'images' => Menu::page(null, 'images', page('page://images')),
On my local environment everything work fine but on my server I couldn’t access this page. I have an error message :
Could not find Panel view for route: images
On the image fields which use this configuration I also have an error message :
“site.find(‘page://images’)” could not be resolved as a valid parent for the upload
If someone have an idea to solve that…
Thanks !
den
November 30, 2024, 6:31am
3
I have find an another way to do what I want here : panel | Kirby CMS
But is still have the error on my hosting provider…
“site.find(‘page://images’)” could not be resolved as a valid parent for the upload
My field is simply defined as this :
label: field.image.label
type: files
uploads:
parent: site.find('page://images')
template: image
multiple: false
image:
cover: false
info: "{{ file.alt }}"
query: site.find('page://images').images.filterBy('template', 'image')
texnixe
November 30, 2024, 8:48am
4
den:
(‘page://images’
What is this? What is the page:// part doing there? Is images
a manually assigned uuid?
den
December 1, 2024, 9:15pm
5
You are right !
I have changed for the following code, it works now.
Thank you
label: field.image.label
type: files
uploads:
parent: site.children.template('images').first()
template: image
multiple: false
image:
cover: false
info: "{{ file.alt }}"
query: site.children.template('images').first()