Why doesn't this work in IE...it works in FF, Chrome, all others

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • virtualkarma
    New Member
    • Sep 2012
    • 1

    Why doesn't this work in IE...it works in FF, Chrome, all others

    Code:
    <script>
    function fred(id,rowCt,ct,cbl)
    {
    	var cols= new Array();
    	cols[0]=50;
    	cols[1]=300;
    	cols[2]=600;
    	var numCol=cols.length;
    	
    	var firstRow=10;
    	var rowOffset=50;
    	var lblOffset=25;
    	
    	var x,xl,y,c;	
    	c=ct%numCol;
    	x=cols[c];
    	xl=x+lblOffset;
    	y=rowOffset+(rowCt*rowOffset);
    
    	id.style.position="absolute";
    	id.style.top=y.toString().concat("px");
    	id.style.left=x.toString().concat("px");
    		
    	cbl.style.position="absolute";
    	cbl.style.top=y.toString().concat("px");
    	cbl.style.left=xl.toString().concat("px");
    }
    </script>
    Last edited by zmbd; Sep 29 '12, 02:23 PM. Reason: Please format your posted code using the <CODE> button.
  • zmbd
    Recognized Expert Moderator Expert
    • Mar 2012
    • 5501

    #2
    virtualkarma

    Welcome to BYTES

    Please do not post code without an explanation. Normally this would be deleted; however, it's your first post.
    And please, in the future, use the <CODE/> format button when posting any type of code or SQL.

    You need to explain what is and is not working with your code. What do you want it to do, what is not doing and any errors you are receiving (error number and description)

    Comment

    Working...