Hi there.
I have created a widget on my webpage that shows customer feedback, which is held on a database.
The div that displays this information is a fixed size so I need to truncate the longer messages and cut it back to the last full word before the character cut off point.
Unfortunately I am stuck.
This is what I have come up with so far:
while($rows=mysql_fetch_array($result)){
?>
<p class="quotes"><? echo strrpos($rows['message'],0,5);?></p>
I have connected to the database correctly, and without the strrpos function, the text displays just fine. But the longer messages, ruin the webpage.
I am a total newbie when it comes to php, so be gentle. Php has only been in my life for a couple of weeks.
Any help would be greatly appreciated. If you could explain where I have gone wrong, it would really help me out.
Many thanks.