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

Remove lead post from rich text body if featured image is being used #17

Closed
wants to merge 3 commits into from

Conversation

bdivver
Copy link

@bdivver bdivver commented Apr 13, 2022

No need for duplicate images

@jwcounts
Copy link

Finally got some time to look at this, and I think I've found a different way to remove the image. Instead of running a regex on the computed layout, I modified get_body_with_layout() to ignore images that are tagged as 'primary' when the dp_npr_query_use_featured option is set to 'true'.

I'm including your updates in the settings.php file, though I did add a check to disable the "theme uses featured images" checkbox if "use layout" is not enabled.

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

Successfully merging this pull request may close these issues.

None yet

2 participants