0 Replies Latest reply on Jun 6, 2015 9:37 AM by migro1982

    Why my script work dont work in IE 11?

    migro1982 Level 1

      this script works fine in Chrome, Firefox and Spartan. But dont work in IE 11

       

       

      tRotationRad=setInterval(RotationRad, 250);

       

       

      // Get Rotaion of the Wheel

         function getRotationDegrees() {

        var matrix = sym.$("Rad").css("-webkit-transform") ||

          sym.$("Rad").css("-moz-transform")    ||

          sym.$("Rad").css("-ms-transform")     ||

          sym.$("Rad").css("-o-transform")      ||

          sym.$("Rad").css("transform");

          if(typeof matrix === 'string' && matrix !== 'none') {

              var values = matrix.split('(')[1].split(')')[0].split(',');

              var a = values[0];

              var b = values[1];

              var angle = Math.round(Math.atan2(b, a) * (180/Math.PI));

          } else { var angle = 0; }

          return angle;

         }

       

       

      // Rotaion of the Wheel

         function RotationRad(){

         var your_angle = 45;

         your_angle = getRotationDegrees() + 45;

         sym.$("Rad").css({

         '-ms-transform': 'rotate(' + your_angle + 'deg)',

         '-ms-transform-origin': '50% 50%',

         '-webkit-transform': 'rotate(' + your_angle + 'deg)',

         '-webkit-transform-origin': '50% 50%',

         'transform': 'rotate(' + your_angle + 'deg)',

         'transform-origin': '50% 50%',

         });

         }