193
rated 0 times
[
196]
[
3]
/ answers: 1 / hits: 30493
/ 11 Years ago, thu, march 14, 2013, 12:00:00
I want to be able to display a string of characters up to 10 characters. If the string goes over 10 characters, I'd like to append '...' to the end.
For example, if I have the string:
'helloworldmynameisryan'
I want it to be displayed like so:
'helloworld...'
I'm just displaying my string in a div like this:
<div>DisplayMessage</div>
Is there a class that I could create that would only apply if the string were over 10 char?
More From » html