Say for example I have the following code:
<h3>My very long title</h3>
<h3>Another long title</h3>
If I wanted to shorten these titles using PHP or jQuery, how can I trim them to the nearest word and append an ellipsis? Is it possible to specify a character count?
<h3>My very long...</h3>
<h3>Another long...</h3>
Edit - How can I do this for each one of the headlines? I don't really have an idea as to how to pass each headline into a string...
Thanks