Ok, so I have an array of words seperated having 'exploded' a load fo text from mysql. Now I'm looking for a method to print only the first 20 words or so (to be followed by a 'click for full story link'....There must be a better way then my current method which is this:
printf ("%s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s %s...",
$text[0], $text[1], $text[2], $text[3], $text[4], $text[5], $text[6],
$text[7], $text[8], $text[9], $text[10], $text[11], $text[12], $text[13], $text[14], $text[15], $text[16], $text[17]);
Can anyone tell me how to print the first 20 parts of an array in one line of code???
Pretty please.....