If string is more than 5 characters append
This will shorten to . . .
by jelane20
HTML
<div class="CalendarViewAllDayEvent"><a href="http://www.google.com">thisisareallylongword </a></div>
JavaScript
if($('.CalendarViewAllDayEvent a').text().length > 5){
str = $(".CalendarViewAllDayEvent a").text();
$('.CalendarViewAllDayEvent a').text(str.substring(0, 5)).append('...');
}