Proxy function instead of fixed url

Hi.

I found the proxy more useful as a function. Pretty simple change.

Cheers,
Dave.