Image AD tracking in banner

This is my tracking code. in header

<!-- Matomo -->
    <script type="text/javascript">
      var _paq = window._paq || [];
      /* tracker methods like "setCustomDimension" should be called before "trackPageView" */
      (function() {
        var u="//";
        _paq.push(['setTrackerUrl', u+'matomo.php']);
        _paq.push(['setSiteId', '1']);
        var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
        g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
    <!-- End Matomo Code -->

This is my AD block. contain 3 image ADs

<div class="card  br-square">
    <div class="card-block slider">
        <a href="" target="_blank" data-track-content>
               <img src="<?php echo base_url();?>assets/dashboard/images/ad3.png" data-content-name="Dashboard AD3" data-content-piece="ad3.png"/>
        <a href="" target="_blank" data-track-content>
                 <img src="<?php echo base_url();?>assets/dashboard/images/ad2.png" data-content-name="Dashboard AD2" data-content-piece="ad2.png"/>
        <a href="" target="_blank" data-track-content>
                 <img src="<?php echo base_url();?>assets/dashboard/images/ad1.png" data-content-name="Dashboard AD1" data-content-piece="ad1.png"/>

i’m trying to track the click and impression of my ads which is in the format of a slider. when user change the slider image, need to track the impression and click for the image in view port.

@Lukas is there any issue in the integration?