How to close a colorbox after an event

How to close a colorbox after an event using jquery in drupal.
Rudra's picture

For closing Colorbox

Use this for closing the colorbox.

parent.jQuery.colorbox.close();

or

$(window).colorbox.close();

Ex:- $("#button_cancel").click(function() { parent.$.colorbox.close(); return false; })