-
-
Notifications
You must be signed in to change notification settings - Fork 174
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[v4] Plugin assets no longer publicly available #5620
Comments
I can reproduce the issue and @distantnative I've reverted your |
I kinda feel responsible for the issue. The PR introduces the possibility to serve files from anywhere in the plugin, "assets" being just a naming convention. So the asset path is now relative to the plugin root, this means that the "assets" part of the path has to be included:
I'm not sure if this is a planned breaking change, or if the default "assets handler" should have mirrored exactly the old behaviour. |
@rasteiner I think that's an oversight from us, we should try to mimic the old behavior to not have such a breaking change |
@rasteiner @SebastianEberlein-JUNO Could you check if the following change fixes it for you: in $assets[$asset] = $path; |
@distantnative Yes, changing the line fixes the problem. |
Description
My test plugin has the following files:
site/plugins/test/index.php
site/plugins/test/assets/style.css
I load the
style.css
in the<head>
like this:In Kirby 3 and Kirby 4 alpha the style.css was copied / linked to the media folder.
In the Kirby 4 beta the file is no longer copied / linked. The browser shows a 404 error for
http://localhost:8888/media/plugins/junohamburg/test/style.css
To reproduce
media
folderSetup
Kirby Version
Kirby v4-beta.1
System
The text was updated successfully, but these errors were encountered: