This is a problem I\'m running into and I\'m not quite sure how to approach it.
Say I have a paragraph:
\"This is a test paragraph. I love cats. Please a
Not sure how to get the complete sentense. but you can try this to get word by word if you split each word by spaces.
This is a test paragraph. I love cats. Please apply here
function splitToSpans(element){
if($(element).children().length)
return;
var arr = new Array();
$($(element).text().split(' ')).each(function(){
arr.push($(''+this+' '));
});
$(element).text('');
$(arr).each(function(){$(element).append(this);});
}