Better is
s|\b([A-Z]+)\b|<i>$1</i>|gm;. Don't use backreferences if you don't have to. They're difficult to debug when they have an error.
Plus, you'll need the /m modifier to match across multiple lines.
Update: As pointed out to me, /m isn't needed here. This is a case of learning a rule early and never learning the reasons behind the rule. (/m is for "multiple lines")
------
We are the carpenters and bricklayers of the Information Age.
Then there are Damian modules.... *sigh* ... that's not about being less-lazy -- that's about being on some really good drugs -- you know, there is no spoon. - flyingmoose