Hi, I have a similar system.. only problem is a band called "The The" :)
we manually entered and corrected the artists http://www.musicexperts.com/ steve At 11:16 PM +0000 24/2/02, Peter Lovatt wrote: >When you add the data > >//does it begin with 'The '? >$name_start = substr($band_name, 0, 2) > >if ($name_start=="The") > { > //remove the word 'The' and following space from the beginning of the >string > str_replace('The ', '', $band_name) ; > > //add ', The 'to the end of the name > $band_name=$band_name.', The'; > } > >You might want something more sophisticated if The with a capital is found >in the middle of names, but hope this is a start > > >Peter >----------------------------------------------- >Excellence in internet and open source software >----------------------------------------------- >Sunmaia >www.sunmaia.net >[EMAIL PROTECTED] >tel. 0121-242-1473 >----------------------------------------------- > >> -----Original Message----- >> From: Jonathan Underfoot [mailto:[EMAIL PROTECTED]] >> Sent: 24 February 2002 18:36 >> To: [PHP-DB] >> Subject: [PHP-DB] "The" Debacle >> >> >> I'm putting together a table with bands, and I have a slight >> problem. Well it not really a problem as much as I'd like some >> input from more seasoned professionals. Certain band names begin >> with "The" but when listing them it would be of great advantge to >> me to remove the "the." Has anyone else faced this dilemma? I >> was thinking that when inputting and editing band names that I >> could just scripot a new column with the comma in place. I >> suppose librarys have this difficulty as well. So what is it? >> >> Column 1 - "The Distillers" >> Column 2 - "Distillers, The" >> >> Or a bit of PHP programming every time I list them (seems more difficult.) >> >> Either way, does anyone have the propper PHP function I should use? >> >> Thanks much... >> >> -Jonathan >> >> > > >-- >PHP Database Mailing List (http://www.php.net/) >To unsubscribe, visit: http://www.php.net/unsub.php -- ------------------------------------------------- "Minds are like parachutes, they work best when open" Support free speech; visit http://www.efa.org.au/ Heads Together Systems Pty Ltd http://www.hts.com.au Email: [EMAIL PROTECTED] Tel: 612 9982 6767 Fax: 612 9981 3081 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php