header to set url php code example Example: header php location header('Location: http://www.example.com/');