Trigger popup from javascript?

It’s a name field from a lookup to another object. I just took a quick crack at adding an onclick even directly to the field definition in XML but that didn’t do it. So how does one add the onclick even to a particular field?