-
-
Notifications
You must be signed in to change notification settings - Fork 194
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
Allow implicit and explicit definition of the default image post #573
Labels
Comments
poppastring
changed the title
Allow implicit and explicit definition of the image post
Allow implicit and explicit definition of the default image post
Nov 22, 2021
The post already has a data field for the URL. That data field should be filled with the upload from the edit page if empty, but should also be settable to an external URL (e.g. Flickr) that might not even be embedded in the post text and then is only used as the teaser image, e.g. in Twitter cards. I would also like a second image URL that can be optionally set for a page banner if the template wants/needs it. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The main image of a blog post is implicitly defined as the first image found in the HTML (see code here), we could make this more explicit in certain scenarios.
My suggestion is to ensure that the image can be identified by a pre-defined class name as follows:
<img class="hero-image" src="/someimge.jpg" >
The code should find this image regardless of where it is in the post and present it as the hero image.
The text was updated successfully, but these errors were encountered: