If you want to rewrite all requests from www.testing123.com to zxy.com with the same URI structure:
server {
listen 80;
server_name www.testing123.com;
rewrite ^ http://zxy.com$request_uri? last;
}
If you want to only rewrite some requests you'll need to use a combination of locations and regex with external redirects depending on the use case.
--
Jim Ohlstein