Skip to content
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

Wrong url for static resource in subfolder #56

Closed
markokocic opened this issue Jun 11, 2021 · 1 comment
Closed

Wrong url for static resource in subfolder #56

markokocic opened this issue Jun 11, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@markokocic
Copy link
Contributor

markokocic commented Jun 11, 2021

I have the following static route defined

(weblorg-copy-static
 :site blog
 :output "output/{{ file }}"
 :url "/{{ file }}")

Inside a static folder I have some files in root, and some in subfolders.

I use {{ url_for("static", file="res/file-1.pdf") }}

Expected behaviour: I would get "/res/file-1.pdf" in generated file.

Actual behaviour: URL without folder gets generated, like this: "/file-1.pdf"

Files are copied to the correct location (in subfolder), it's only links that don't work.

@clarete clarete added the bug Something isn't working label Sep 4, 2021
@clarete
Copy link
Collaborator

clarete commented Sep 4, 2021

hi hi @markokocic, sorry I took quite a bit to get to this one.
I just tried it out and it seems to be working for me, and I am under the assumption that this was actually an error in how the named parameters for functions were being parsed by templatel. Since I just tried it out and it worked, I might mark this bug as closed. If by any chance I just missed something, please reopen it and we'll take a deeper look!

@clarete clarete closed this as completed Sep 4, 2021
clarete added a commit that referenced this issue Sep 17, 2021
There have been other changes to be more flexible, but this change now
allows any character that is not a comma.

Refs: #56
clarete added a commit that referenced this issue Sep 17, 2021
We now accept escaped commas when parsing values in the key-value
pairs of URLs.

Refs: #56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants