Add custom html in outside the fancybox

316 Views Asked by At
 $.fancybox({
        content: '<button>prev</button><button>next</button>',
        href: src,
        'autoScale': false,
        'transitoinIn': 'none',
        'transitionOut': 'none',
       .......
});

I simply open images in fancybox. I want to add some html button in fancybox but problem is that it is override the image. but I don't want to override the image so I want to add button outside the image.

Any help?

1

There are 1 best solutions below

0
Ping Kee Ng On BEST ANSWER

How about you try having z-index?

<style>
.btn1 {z-index: 5;}

</style>
<html>
...
<html>
<script>

$.fancybox({
                content: '<button class="btn1">prev</button><button class="btn1">next</button>',
                href: src,
                'autoScale': false,
                'transitoinIn': 'none',
                'transitionOut': 'none',
               .......
        });

Or you can try having your buttons in the html and position it to absolute.