0 Replies Latest reply on Jan 14, 2013 1:25 PM by Paulcardo

    Orientation change button align from right to left

    Paulcardo Level 1



      On vertical view I want the button to be aligned to the right,

      and when is horizontal, align the button to the left


      I have put this code in the orientationchange event:


      if(window.innerHeight > window.innerWidth){

          sym.$("btnDeal").css('right', '10px');  // vertical

      } else {

         sym.$("btnDeal").css('left', '80px');  // horizontal



      I open the site in vertical mode, button looks good,

      change orientation to horizontal then the button change position, looks good

      now I put vertical again, this time the button is wrong, it stayed to the left, should go to the right.

      any change in the orientation the button keeps to the left

      please help, What Im doing wrong?