new function to identify appropriate language from xmL;lang (thanks to Syd)