I get it, I think. Now, this was an interim update, and that means I am already working on the next phase. I'm going to include these modifications as optional properties, and they need to degrade gracefully (all other things being equal, appear in its more normal location below bottom, center of the image container) when the dimensions aren't available in the browser. To that end, here is the new code for the code we changed before:
Code:
if(this.descriptions){
this.go('imgdsc'+this.issid).innerHTML = this.imgs[this.keeptrack()][1];
if(this.move_desc_up&&(this.tmph=this.go('theimg'+this.keeptrack()+'_'+this.issid).offsetHeight)&&this.tmph>0) //move description up for shorter images - requires position relative for #imgdsc$
this.go('imgdsc'+this.issid).style.top=(this.tmph-this.height)/2+'px';
if(this.desc_pic_width&&(this.tmpw=this.go('theimg'+this.keeptrack()+'_'+this.issid).offsetWidth)&&this.tmpw>0) //set description width to pic width
this.go('desc'+this.issid).style.width=this.tmpw+'px';
}
It replaces:
Code:
if(this.descriptions){
this.go('imgdsc'+this.issid).innerHTML = this.imgs[this.keeptrack()][1];
if(this.go('theimg'+this.keeptrack()+'_'+this.issid).offsetHeight)
this.go('imgdsc'+this.issid).style.top=(this.go('theimg'+this.keeptrack()+'_'+this.issid).offsetHeight-this.height)/2+'px';
}
And requires new code here (red):
Code:
. . . bstyle=imgs.border_style;
this.width=imgs.width? imgs.width : width? width : null
this.width=this.width? this.width+this.imgborder*2 : null;
this.height=imgs.height? imgs.height : height? height : null
this.move_desc_up=imgs.move_desc_up;
this.desc_pic_width=imgs.desc_pic_width;
this.height=this.height? this.height+this.imgborder*2 : null;
var ief='', dims='';
if(this.wid . . .
And to be active for a given show, requires that these properties are set for the array:
Code:
. . .
slides.no_auto=1; //use to make show completely user operated (no play button, starts in stopped mode)
slides.image_controls=1;
slides.button_highlight='#FFFFFF';
slides.move_desc_up=1;
slides.desc_pic_width=1;
. . .
Once you have all that in place, set the style for #desc0:
Code:
#desc0 {
text-align:right;
margin:0 auto;
}
and you should be in business. I see you currently have this selector float:right, but that won't do for the effect you are after.
Bookmarks