On the existence of extremal functions for a weighted Sobolev embedding with critical exponent