posted 13 years ago
I have a requirement where I am using the portable device to display my webpage. my webpage is having 3 buttons; button1,button2 and button3 . button1 positioning at right corner of the screen and button2 at left corner of the screen. For button2, on page load i am taking the screen width and placing button2 at the middle of screen. the problem is, if i rotate the device to portrait to landscape then my button2 does not fit to the screen. can you please let me know how we can achieve this using by javascript ? so that button2 should set the position irrespective of screen resolution.