I see. Well it appears this is a bug or missing feature and our interface doesn't allow you to have code in the redirect field.
Instead of using:
<?php echo((isset($_SERVER["SERVER_NAME"]))?$_SERVER["SERVER_NAME"]:"") ?>
try using:
" .((isset($_SERVER["SERVER_NAME"]))?$_SERVER["SERVER_NAME"]:""). "
In general, only fields with lighning bolts will support dynamic values. I will log this as a feature request to accept dynamic values in the redirect fields of the checkout wizard in the next version.