Added the matching element to placeholder resolver callbacks

When a function is assigned to provide the replacement value for a
placeholder variable, the DOMNode in which the placeholder resides is
now provided as third argument. This is either a DOMText (nodeType 3)
or DOMAttr (nodeType 2) element