Help - Search - Members - Calendar
Full Version: Masstagger Problem
Hydrogenaudio Forums > Hosted Forums > foobar2000 > General - (fb2k)
wolfsong
I'm using the following to capitalize and "fix" titles.
CODE
$replace($caps2(%title%), A , a ,Dj,DJ, The , the , At , at , By , by , With , with , And , and , But , but , Of , of , In , in , Or , or , To , to )

But if there is an occurance of 2 words like of the "the" will end up being capitalized. Any ideas how to avoid this?
golphcart
it's messy and long but I think this will do. btw, this is discussed in the wiki

The relevant text:

Can also be used with an arbitrary number of arguments. Note that $replace(a,b1,c1,b2,c2) is generally not the same as $replace($replace(a,b1,c1),b2,c2).

Example: $replace(ab,a,b,b,c) → "bc", $replace($replace(ab,a,b),b,c) → "cc"

CODE

$replace($replace($replace($replace($replace($replace($replace($replace($replace($replace($replace($replace($caps2(%title%), A , a ),Dj,DJ), The , the ), At , at ), By , by ), With , with ), And , and ), But , but ), Of , of ), In , in ), Or , or ), To , to )


- golphcart
wolfsong
QUOTE(golphcart @ Nov 20 2006, 17:26) *

it's messy and long but I think this will do. btw, this is discussed in the

Thanks!
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.