Fancybox is a superb tool for adding a lightbox-style popup to your web app. And Fancybox2 (the paid version) adds some very nice features and occasional updates, all well worth the trivial cost. The docs are incorrect however as to how to specify some of the open() options.

The fancybox2 v2.1.5 docs for the API call open() says

$.fancybox.open( [group], [options] )

However the docs go into detail about [ group ] and say nothing about the format expected for the [ options ]

Furthermore the options seem to be ignored.

When I use

$.fancybox.open([{ href : ‘#popup_panel’ }], [ { ‘title’ : ‘Title Two’, ‘minWidth’ : 500 }] );

or

$.fancybox.open([{ href : ‘#popup_panel’ }], [ { title : ‘Title Two’, minWidth : 500 }] );

Fancybox seems to ignore the options… it opens, but there is no title and the minWidth is ignored.

Turns out, the fancybox documentation is wrong; options go inside the [group] apparently:

$.fancybox.open([{ href : ‘#popup_panel’, title : ‘Title Two’, minWidth : 500 }], [] );