Last active
December 14, 2021 16:24
-
-
Save ferdman/ff3cfeda13d5d08704e68506388662c2 to your computer and use it in GitHub Desktop.
WP Job Manager: Add company logo to the job feed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'job_feed_item' , 'rss_add_company_logo' , 10 , 2); | |
function rss_add_company_logo ( $company_logo ) { | |
$company_logo = get_the_company_logo( $post_id); | |
if ( $company_logo ) { | |
echo '<enclosure type="image/jpeg" url="'. esc_html( $company_logo ) . '"/>'; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment