I've been trying to use jquery's dotdotdot method in order to cut off overflowed text, but for some reason it's not working. I was hoping the method would be pretty simple, but I don't know what I'm doing wrong.
Javascript:
$(document).ready(function(){
$('.dotdotdot').dotdotdot({
ellipsis: '... ',
wrap: 'word',
after: null,
watch: true,
height: 40
});
});
html:
<div class="dotdotdot">
<?php echo $description; /*Current div height with text exceeds 40px*/ ?>
</div>
I cant find anything that would explain why this isn't working. My jquery is up to date, version 1.8.3.