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

links to event assets don't work on home page #57

Open
johnwbryant opened this issue Nov 17, 2023 · 7 comments
Open

links to event assets don't work on home page #57

johnwbryant opened this issue Nov 17, 2023 · 7 comments
Assignees
Labels

Comments

@johnwbryant
Copy link
Contributor

johnwbryant commented Nov 17, 2023

Something to do with the routing I think. Links work OK from the event page but not from the home page, where they give you this:

image

eg. one of the QGIS template links from this week's event resolves as follows:

@BudgieInWA
Copy link
Contributor

Makes sense, because the markdown is using relative links and the home page is rendering the content "out of context". @samwilson do you think there is a way to access the event page's path in order to repair the link in the home page template?

We could use absolute paths in the markdown (starting with /2023/) but then the event pages wouldn't be portable any more, and the markdown links would only be correct in the context of the website (whereas they are currently correct in the context of the file system too).

@johnwbryant
Copy link
Contributor Author

Could we put it in a block that only displays if it's on the event page rather than the home page? Because in practice we only put assets up once the event is over. In fact we could probably just make it a practice to remove the event from the home page when it's done...

@BudgieInWA
Copy link
Contributor

That sounds sensible too.

Maybe we could be fancy - now that we have the dates stored as comparable values - and have an "upcoming" section with full descriptions, and a "recent" section with the latest one or two events, but only show the first paragraph or first x characters of the descriptions, and link to the page.

@BudgieInWA
Copy link
Contributor

I think we should add a "horizontal rule" ---\n separating the event description from all the rest, and using the page.excerpt (with the setting turned on for the build) to put just the event description on the front page, linking to "more".


Above the rule is the meat of my comment, and here I can link to random stuff and update historical stuff without effecting the thing I'm trying to describe above the line.

@samwilson
Copy link
Member

That sounds good.

Does Jekyll use the HR as a marker for page.excerpt?

@BudgieInWA
Copy link
Contributor

In Jekyll, you can specify a custom separator for excerpts using the excerpt_separator option in the _config.yml file. This separator tells Jekyll where to stop when creating the excerpt for the page.

Let's go with something specific like a 5 dash hr.


excerpt_separator: -----

@samwilson
Copy link
Member

That sounds like a good idea.

@BudgieInWA BudgieInWA added the bug label Dec 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants