Hello,
I had the same issue but I found a solution...
For my project, I must use the browser's scrollbar instead of shadowbox's. So I edit the shadowbox.js but not dynamicly...
You have to change the adjustHeight function. ( Line 1876). The first thing si to give a sb.style.height which is not dynamic.
In my case, i wrote : sb.style.height = '1024px';
This line prevents the shadowbox to resize its height automatically.
Then you need to change the top of the SB. When my scroll bar is on top, my shadowbox has a 15 px padding-top. But you can change that value has you want. And, when you will scroll, the SB should stay at the same place. To do that, you should calculate the right padding top.
I first create a variable :
var scrollHeight = window.pageYOffset ||
document.body.scrollTop ||
document.documentElement.scrollTop;
This var will be the distance between the top and the scroll position. Then i will use the "t" variable from the adjustHeight function, and calculate the right style.top
==> t = 15 - scrollHeight ;
Now, when you will resize your window, the sb will be at the right place, without scrollbars.
But, we would that the sb will be at the same place when we scroll... so i just add a little javascript function under the adjustHeight function.
==> window.onscroll = function() {adjustHeight()};
And now, it works... :-).
When you scroll your window, the sb does'nt move and you can see all you iframe, or sb content by scrolling the main window.
MoKeS