Setting width to X and height to Y on the greybox settings page has the effect of the box actually having a width of Y and a height of X.

That happens, because the GB_show() function takes parameters in the wrong order:

The greybox_add_files() function in greybox.module produces the javascript code:

...
var t = this.title || $(this).text() || this.href;
GB_show(t,this.href,' . $width . ',' . $height . ');
return false;
...

But greybox.js contains:
...
function GB_show(caption, url, height, width) {
...

The problem can be easily solved by switching "height" and "width" in the GB_show function inside greybox.js.

I do not know how to patch'n stuff, I'm just submitting this so someone else could do it.

Comments

Gurpartap Singh’s picture

Status: Active » Fixed

Thanks!

Anonymous’s picture

Status: Fixed » Closed (fixed)