I've got a blog with lots of div.content
s, each of which I'd like to have a height as a multiple of 22px (so all the text lines up with a background image of a grid). I'm imagining you'd probably do something like:
// loop for each div.content
// var height = $('div.content').height()
// var modulus = height%22
// var padding = 22 - modulus
// $('div.content').css({'padding-left': 'PADDINGpx'})
Does that sound about right? I'm not too great with JS. How do you get the padding variable into the jquery function?
Thanks in advance!