View Full Version : Dock Content script Horizontal Please

10-31-2008, 02:11 AM
1) Script Title: Dock Content script

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex17/dockcontent.htm

3) Describe problem: I found the script I've been looking for however; my website is horizontal scroll only :(

Is there a way someone can rearrange the script to allow the docking for horizontal scroll...right now it only works for vertical. I would like for the mp3 player to be docked.


10-31-2008, 03:45 PM
It would probably be simpler and look better to just use fixed positioning. This will not work for IE 6 and below though. If that's important to you (and I think it would/should be), there's a fairly simple workaround for that.

For fixed positioning, you just use style, say your element has a class of fixedPos (for example, in your stylesheet):

.fixedPos {
position: fixed;
left: 30px;
bottom: 20px;

Then for IE 6 and less, you can add this conditional code and stylesheet below that:

<!--[if lt IE 7]>
<script type="text/javascript">
function fixedIE(tl, n){
var sc='scroll'+tl, d=document, c='compatMode';
return d[c] && d[c]=='CSS1Compat'? d.documentElement[sc]+n+'px' : d.body[sc]+n+'px';
<style type="text/css">
.fixedPos {

10-31-2008, 05:49 PM
Thanks for the response.. :) will this allow the docked div to continuously be on the screen even though scrolled horizontal? Should I remove the java scripting? or include the fixed positioning with the code that is already in place?:confused:

10-31-2008, 07:23 PM
Yes it will. Yes remove the script.

11-03-2008, 07:03 PM
Thanks for the posting I ended up changing the entire website design. But I will definitely use this in future projects.