﻿(function ($) {
// VERTICALLY ALIGN FUNCTION
$.fn.vAlign = function() {
	return this.each(function(i){
	var ah = $(this).height();
	var ph = $(this).parent().height();
	var mh = (ph - ah) / 2 + 'px';
	/*$(this).css('padding-top', mh);
	$(this).css('padding-top', mh);*/
	$(this).parent().css('position', 'relative');
	$(this).css('position', 'absolute');
	$(this).css('top', mh );
	});
};
})(jQuery);