johndoe johndoe - 9 months ago 52
Javascript Question

image rotation using input box?

How can I make text rotation using an input box to manipulate the rotation. I had text rotation using mouse but that got to be really complicated when I used draggable.
Please help me


I hope this will guide you to accomplish it

       var x= $("#rotateInput").val();      
     $("#rotate").css('transform','rotate(' + x + 'deg)');
  background: url('');
   width: 180px;
  margin:40px auto;
<script src=""></script>

   <div id="rotate"></div>

<input id="rotateInput" type="text" value="0">
<button id="rotateButton">Rotate It</button>