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

coverimage doesn't work with relative URL unless leading / added #236

Closed
zeigerpuppy opened this issue Nov 21, 2017 · 3 comments · Fixed by #358
Closed

coverimage doesn't work with relative URL unless leading / added #236

zeigerpuppy opened this issue Nov 21, 2017 · 3 comments · Fixed by #358
Labels
bug Something isn't working enhancement New feature or request
Milestone

Comments

@zeigerpuppy
Copy link

zeigerpuppy commented Nov 21, 2017

Configuration

  • Hugo version: 0.31
  • Tranquilpeak version: 0.4.3-BETA

Actual behavior

In a post header, adding a coverImage works with a URL but not a relative link, unless a leading / is added.

Expected behavior

A relative link should work without a leading slash (it does for thumbnailImage).

this fails for an image in static/images/posts/

coverImage: images/posts/hugo_cover.jpg

this works

coverImage: /images/posts/hugo_cover.jpg
@kakawait kakawait added the enhancement New feature or request label Nov 21, 2017
@kakawait kakawait added this to the 0.4.4-BETA milestone Nov 21, 2017
@kakawait
Copy link
Owner

Thank for reporting i will checkout how to fix it.

@Titan-C
Copy link

Titan-C commented Jul 7, 2019

Currently in master is not great. I had for coverImage an Image from another host. Thus

coverImage: https://some.host/_images/img.jpg

The current solution prefixes an "/" making then the address invalid /https.//somehost. Maybe this is a bad practice and I should use // for external links but that as long as everybody is using https.

@kakawait
Copy link
Owner

kakawait commented Jul 7, 2019

@Titan-C not is a bug I reopen issue i will fix it on minor release 0.4.4-BETA

@kakawait kakawait reopened this Jul 7, 2019
@kakawait kakawait modified the milestones: 0.4.5-BETA, 0.4.6-BETA Jul 10, 2019
@kakawait kakawait added bug Something isn't working and removed fixed on develop labels Jul 10, 2019
kakawait added a commit that referenced this issue Jul 10, 2019
use `relUrl` instead

fixes #236 and #321 and #305
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants