The AJAX content loaded in a Colorbox has some JavaScript included that resizes things within the content. Colorbox determines its sizing based on the sizes before all of the AJAX happens. How can I make the Colorbox resize after the content has been loaded?
Here is a link where someone said that you can call colorbox() again after it's been loaded, but I can't figure out how to do that:
http://groups.google.com/group/colorbox/browse_thread/thread/535d21c69e9006b0
Not sure what you are looking for but I found this thread while on a quest for my own solution. I have a colorbox in iframe mode. There is a button in there that when clicked, needs to replace the current colorbox with a new one. I just do this...
This reloads a new page into a new colorbox in the same location and the transition is very smooth.
In Colorbox 1.3, you can now call the resize function:
This one is working properly brothers.
As I know, colorbox with
iframe: true
, cannot be resized. Color withiframe: false
can resize height only (usingjQuery.fn.colorbox.resize()
).This Can be done if you can detect the height/width of the content in iframe, then you can use colorbox.resize() function to resize the colorbox again.
To dynamicly resize colorbox you want to say.
If you want to resize a color box that loads an Iframe you would add something like this to the head of your target document.