I have the following basic setup: A Staff Page (page type) that display Staff (dataobject). I have the Staff Page displaying the Staff dataobjects the way I'd like. They have all the necessary info and a Bio. I limit the bio to 50 words and have a read more link to show the full bio if someone clicks on it. However I would only like to show the 'Read More' link only if the Bio word count is above 50. I'm assuming I could write a function in the Staff Page controller for that. That would return a boolean for the word count above or below 50, but I'm having trouble writing that. Can anyone point me in the right direction, or know the code I would need?
Thanks in advance!