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

I've installed the plugin but I have no idea how to call the images #85

Open
MrJarrad opened this issue Jan 16, 2020 · 4 comments
Open

Comments

@MrJarrad
Copy link

Hi there,

I'm very new to Wordpress in a coding sense. I've installed your Dynamic-Featured-Image plugin as i want to be able to use a different image for a portfolio slider on my website. I have no idea how to update the code to make it do that. Are you able to assist?

@ankitpokhrel
Copy link
Owner

@MrJarrad
Copy link
Author

Thanks for getting back to me @ankitpokhrel.

Sorry I didn't really explain. I did see the link you provided earlier. What I meant was I have no idea where I should insert the provided code or what code I need to replace it with.
I've attached one of my templates in my theme. If you can shed some light on where I would insert the Dynamic Featured image code, it would be extremely helpful.

Thanks for your time and assistance.

Cheers,
Jarrad
style2.txt

@MrJarrad
Copy link
Author

Any advice?

@shpemu
Copy link

shpemu commented Aug 15, 2023

@MrJarrad hey there. I added this code to my single.php file within my theme:
if( class_exists('Dynamic_Featured_Image') ) { global $dynamic_featured_image; $images = $dynamic_featured_image->get_featured_images( get_the_ID() ); foreach( $images as $image ) { echo '<img src="' . $image['full'] . '" />'; } }

I hope that helps!

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

3 participants