我想下面的jQuery後添加此HTML標記<a href="#">Read More</a>
用substr JQuery返回一個html標籤?
$("span.fine-print").text(function(index, currentText) {
if (currentText.length > 200) {
return currentText.substr(0, 200)+'...';
}
});
如何補充說,「更多」後,此鏈接。 任何幫助非常appriciate。謝謝,
http://viralpatel.net/blogs/dynamically-shortened-text-show-more-link-jquery/ –