RE: [PHP] Displaying first 20 characters of a comment

2002-12-19 Thread Jon Haworth
Hi Kevin, > I am trying to find out what the best way is to display only > the first 20 or so characters of a comment. [...] > I am not sure if it is best to do it with the select statement > or format it with the PHP. Either way I am not sure how. If you only want the first 20 characters, an

RE: [PHP] Displaying first 20 characters of a comment

2002-12-19 Thread Quentin Bennett
destroy this email and contact the sender immediately. Your assistance is appreciated. select left(myfield,20) from mytable; -Original Message- From: Kevin Meredith [mailto:[EMAIL PROTECTED]] Sent: Thursday, 19 December 2002 11:03 p.m. To: PHP Subject: [PHP] Displaying first 20 characters of

[PHP] Displaying first 20 characters of a comment

2002-12-19 Thread Kevin Meredith
Hi. I am trying to find out what the best way is to display only the first 20 or so characters of a comment. The comments which are entered separately by users are stored in a MySql database. I am displaying a list of the last 5 entries on the home page and then linking them to the relevant comm