How can I make a table move in JavaScript?

Problem

My problem is that I was creating a simple website the other day and I needed the content to move according to the button pressed.

I managed to do so in CSS3, but the solution did not work for IE whatsoever. Therefore I would like to ask if there is a simple solution for that in js? I don't know js at all but I heard what I need is much easier in js than in css.

Details:

http://i42.tinypic.com/6yl4ia.png

I need the table in the picture to move according to the buttons (which are labels to be exact).

The visible area is a div.

Here's the relevant code (without animation as I was not satisfied with it):

body {
background-color: #fff;
color: #fff;
padding:0px;
}


#bodywrapperfixed {
width: 1248px;
margin: 0px auto;
position: relative;
overflow: hidden;
height: 730px;
}


#bodywrapper {
display:block;
background-color: #fff;
width: 1248px;
color: #59595B;
padding-top:50px;
font-family: 'Roboto', sans-serif;
position: absolute;
top:0px;
left:0px;
z-index:1;
font-size: 60px;
height:730px;
}

#bodywrapper img {
width:400px;
padding:15px 0px 20px 0px;
}

#texten {
font-family: 'Roboto', sans-serif;
font-size: 35px;
padding:5px;
}

#textpl {
font-family: 'Roboto', sans-serif;
font-size: 25px;
padding:5px;
}



table#linki {
width: 110px;
border: none;
margin-top:15px;
}





label {
  display: block;
  height: 54px;
  width: 54px;
  color:#fff;
  font-family: 'Roboto', sans-serif;
  font-weight: 300;
  font-size: 35px;
  background-color: #117D10;
  text-align: center;
  padding:23px;

}

label:hover {
  background-color: #004F00;
  cursor: pointer;
}

input#pl {
   position: absolute;
   top: -9999px;
   left: -9999px;
}

input#en {
   position: absolute;
   top: -9999px;
   left: -9999px;
}

and the relevant HTML:

<div id="bodywrapperfixed">
<div id="bodywrapperfloat">
<table id="ramka">
     <tr>
          <td>random text</td>
          <td><div id="bodywrapper">
<center>
<div id="texten"><div style="font-weight:300; display:inline-block;">Introducing the all-in-one entertainment system.</div><div style="font-weight:500; display:inline-block;">&nbsp;For everyone.</div></div>


<div id="textpl"><div style="font-weight:300; display:inline-block;">Przedstawiamy zintegrowany system rozrywki.</div><div style="font-weight:500; display:inline-block;">&nbsp;&nbsp;Dla wszystkich.</div></div>


<img src="imgs/xboxone.png">


<div id="texten"><div style="font-weight:300; display:inline-block;">Choose your version of the story:</div></div>


<div id="textpl"><div style="font-weight:300; display:inline-block;">Wybierz swoją wersją opowieści:</div></div>




<table id="linki">
<tr>
<td><label for="en">en</label><input id="en" type="checkbox"></td>
<td><label for="pl">pl</label><input id="pl" type="checkbox"></td>
</tr></table>
</center>
</div></td>
          <td>random text</td>
     </tr>
</table>
</div>
</div>

Here's what it looks like:

http://ingame.lh.pl/thinkone/

Please help me.

Problem courtesy of: Michał Skrzypek

Solution

CSS3 Transformations will not work in IE9 and below since they simply don't support it. If you need to do transforms and the like then one of the many options available is jQuery.

jQuery is a JavaScript Library that simplifies your use of JavaScript and makes DOM Manipulations like transformations and animations simpler. They have a number of great demos on their website that should help you get started. I would recommend having a look at their own JavaScript 101 which will help you get started with the basics of JavaScript itself (without jQuery) and then lead you into making your life easier with jQuery.

For specifically what you are after (what I assume you are after anyway) you may want to have a look at their events tutorial (attaching click handerls to elements etc.), css styling tutorial (CSS 'Getting, Setting and Manipulations') and the effects tutorial (Attaching effects to elements).

I hope this helps get you started in the world of JavaScript and jQuery. Note that many other libraries exist, but this one is the one you will see the most of everywhere.

Solution courtesy of: Rob Quincey

Discussion

Hope this helps..The code contains a table and buttons as you depicted in the picture http://jsfiddle.net/ramanbedi/vDdJL/ here is the js code:

$(function(){
    $(".left-button").on('click',function(e){
        e.preventDefault();
        $(".table").animate({left:'-=10'},500);
    })
    $(".right-button").on('click',function(e){
        e.preventDefault();
        $(".table").animate({left:'+=10'},500);
    })
})

I have used jQuery library and reasons are mentioned in the comments.

Discussion courtesy of: Raman

This recipe can be found in it's original form on Stack Over Flow.