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

Internal Calendar & other links do not preview. #23

Open
samuk opened this issue Apr 28, 2022 · 6 comments
Open

Internal Calendar & other links do not preview. #23

samuk opened this issue Apr 28, 2022 · 6 comments

Comments

@samuk
Copy link

samuk commented Apr 28, 2022

When posting links to Humhub calendar entries into Humhub spaces there is no preview.

When posting links to (public) Humhub posts into spaces there is no preview.

@marc-farre
Copy link

The problem seems to be on all Humhub instances (tested with 3 different Humhubs and with public contents that can be viewed without login).

/linkpreview/index/fetch returns the error "Title cannot be blank.":

{url: "https://my-humhub.tdl/s/space-name/calendar/entry/view?id=14",…}
output: {og:site_name: null, og:title: null, og:description: null, og:image: [], og:type: "website",…}
errors: ["Title cannot be blank."]
0: "Title cannot be blank."
og:description: null
og:image: []
og:site_name: null
og:title: null
og:type: "website"

The the <title> tag is present and not blank. Or maybe it's another title? I didn't investigate more.

@aaukt
Copy link

aaukt commented May 3, 2022

AFAIR the old version had a fallback to use the <title> attribute if the og:title metadata was missing (and maybe also thesame for the description). The new version does not have that fallback. Technically this seems to be correct as https://ogp.me/ doesn't list the title as optional. So sites without any opengraph metadata or missing title won't work anymore.

@samuk
Copy link
Author

samuk commented May 3, 2022

So should this issue be re-framed as 'Humhub should have opengraph metadata'? Is that the problem?

This should be closed and this ticket humhub/humhub#3506 worked on?

@aaukt
Copy link

aaukt commented May 3, 2022

For public available posts humhub/humhub#3506 would solve the problem i think.

For posts behind login it wouldn't help. For that i would prefer if 403 errors/redirects would not be parsed at all.
If you want a preview for internal links it might create a security issue if the preview module could access anything.

@samuk
Copy link
Author

samuk commented May 3, 2022

In my case all links are public. I'll see if I can get anyone to work on #3506

@luke-
Copy link
Contributor

luke- commented May 16, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants