Im currently using some jQuery code to place a logo (which is 150px wide) dead center between some navigation li items.
I have found the width of the window, divided by 2 then subtracted half the logo width to get it center of screen.
$window = $(window);
winW = $window.width();
winH = $window.height();
// Position Navigation Logo
left: winW / 2 - 75
This works great, however when i resize the window the logo position needs to be recalculated so it stays in the center position. Can anyway suggest the best way to go about this?
Any feedback will be appreciated.