By Philippe on Friday, 16 April 2021
Posted in Technical Issues
Likes 0
Views 757
Votes 0
Hello,

For images, why is there an A tag when there is no link ?

In /components/com_easyblog/themes/wireframe/blogs/blocks/image.php

If the popup_url is empty, shouldn't the A tag be replaced by a div ?

<?php if (empty($block->data->popup_url)) { ?>
<a class="eb-image-viewport"<?php echo $imageLinkAttr; ?>>
<?php } ?>
<img src="/<?php echo $block->data->url;?>" <?php echo isset($block->data->alt_text) && $block->data->alt_text ? 'alt="' . $block->data->alt_text . '"' : '';?>
<?php echo $imageElementAttr; ?>/>
</a>


By :

<?php if (empty($block->data->popup_url)) { ?>
<div class="eb-image-viewport"<?php echo $imageLinkAttr; ?>>
<img src="/<?php echo $block->data->url;?>" <?php echo isset($block->data->alt_text) && $block->data->alt_text ? 'alt="' . $block->data->alt_text . '"' : '';?>
<?php echo $imageElementAttr; ?>/>
</div>
<?php } ?>


Thank you,
Philippe
We use anchor to standardize it. It really does not matter what tag we use anyway.
·
Saturday, 17 April 2021 11:40
·
0 Likes
·
0 Votes
·
0 Comments
·
Ok thank you
·
Saturday, 17 April 2021 15:57
·
0 Likes
·
0 Votes
·
0 Comments
·
No problem
·
Sunday, 18 April 2021 11:38
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post