Orientation change button align from right to left


hi,

 

on vertical view want button aligned right,

and when horizontal, align button left

 

i have put code in orientationchange event:

 

if(window.innerheight > window.innerwidth){

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

} else {

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

}

 

i open site in vertical mode, button looks good,

change orientation horizontal button change position, looks good

now put vertical again, time button wrong, stayed left, should go right.

any change in orientation button keeps left

please help, im doing wrong?

 

thanks



More discussions in Edge Animate CC


adobe

Comments

Popular posts from this blog

Warning, the Safe Path is not accessible vm3 - Joomla! Forum - community, help and support

uppercase letters in url - Joomla! Forum - community, help and support

Joomla! Update is not offering Joomla 3 - Joomla! Forum - community, help and support