Here is my jQuery:
<script src="../js/jquery.min.js"></script>
<script type="text/javascript" src="../js/thickbox.js"></script>
<script type="text/javascript"
$('#button').click(function(){
$('#TB_window').fadeOut();
});
</script>
Html:
<input type="submit" id="button" value="clse" >
I tried this function, but it's not working.
Thickbox have their built in method. tb_remove
just call this method tb_remove();
wherever you need. It will close thickbox properly.
If you use $('#TB_window').fadeOut();
, TB_overlay DIV will remain open. If you again do something nonsense like $('#TB_overlay').fadeOut();
then it will create problem for your thickbox. And thickbox will stop function.