base64 image open in new tab with fancybox, instead of the classic "popup"

1.1k views Asked by At

i don't know why but i have two type of gallery, one of that use fancybox and isotope plugin and if i pass image in this format:

<img src="data:image/jpg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD// gA8Q1JFQVRPUjogZ2QtanBlZyB2MS4wICh1c2luZyBJSkcgSlBFRyB2NzApLCBxdWFsaXR5ID0gMTAwCv/bAEMAAQEBAQEBAQEBAQEB...... 

it work, and the code is that (showing image from mysql):

  <a class="fancybox img-responsive" href="data:<?php echo $dati['image_type'];?>;base64,<?php echo base64_encode($dati['image_big']);?>" data-fancybox-group="gallery" title="">
                        <img src="data:<?php echo $dati['image_type'];?>;base64,<?php echo base64_encode($dati['image_big']);?>" class="img-responsive all <?php echo $nome_album;?>" alt="gallery">
                        </a>

But if i use this code (which work with isotope and fancybox togheter):

  <a class="fancybox img-responsive" href="data:<?php echo $dati['image_type'];?>;base64,<?php echo base64_encode($dati['image_big']);?>" data-fancybox-group="gallery" title="">
                        <img src="data:<?php echo $dati['image_type'];?>;base64,<?php echo base64_encode($dati['image_big']);?>" class="img-responsive all <?php echo $nome_album;?>" alt="gallery">
                        </a>

It does not work.. i made some search but the solution i found is for an older version of fancybox..

0

There are 0 answers