j = jQuery.noConflict();

/* Truncate Text */
function truncateText (element, length) {
	j(element).each(function() {
		var str = j(this).text();
		var limit = length;
		var bits, i;
		
		bits = str.split('');
		if (bits.length > limit) {
			for (i = bits.length - 1; i > -1; --i) {
			if (i > limit) {
			bits.length = i;
			}
			else if (' ' === bits[i]) {
			bits.length = i;
			break;
			}
			}
			bits.push('...');
		}
		var truncate = bits.join('');
		j(this).text(truncate);
	});
}

j(document).ready(function(){
truncateText(j("body#pageId0.browse div.hpTitlePrice h4 a"), 60);
truncateText(j("div.hpTitlePrice h4 a, body.detail #bottom-2 h4 a"), 60);
})

