FEATURE Handlign cite button
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
56208a06d8
commit
562be8f9a7
|
|
@ -2,11 +2,13 @@
|
|||
$currentPostType = get_post_type();
|
||||
$shareUrls = build_share_urls();
|
||||
$handleCitation = post_type_supports($currentPostType, 'carhop-citations') ?? false;
|
||||
$citeReference = get_field('cite_reference', get_the_ID());
|
||||
// write_log($handleCitation);
|
||||
?>
|
||||
|
||||
|
||||
<div class="socials-buttons">
|
||||
<?php if ($handleCitation) : ?>
|
||||
<?php if ($handleCitation && !empty($citeReference)) : ?>
|
||||
<button class="socials-buttons__button socials-buttons__button--cite" <?php echo empty($citeReference) ? 'disabled' : ''; ?> title="<?php echo empty($citeReference) ? 'Citation non disponible' : 'Copier la citation'; ?>">
|
||||
<img src="<?php echo get_template_directory_uri(); ?>/resources/img/icons/carhop-citer-article.svg" alt="">
|
||||
Citer
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user