This is just a revamp of a function I wrote a while back to add the ability to limit the number of words displayed when you call the excerpt or…