PDA

View Full Version : Smaller poll questions


SeanThomps
03-02-2005, 03:32 AM
Hey,

I display some of the polls users make, and the poll questions have recently been too long. Is there any way of restricting the amount of characters?

HiDeo
03-02-2005, 04:22 AM
You can use strlen:


if (strlen($question) > XX)
{
$question = substr($question,0,XX) . "...";
}

XX is the number of characters !