You just sent an ajax request on the front end instead of a page jump.
Either let the backend return json data, and the frontend uses js to jump to the landing page according to its content; or the frontend jumps directly to the target address, and let the backend redirect to the landing page.
The return data of the ajax request will be processed in the return function function(data, status). You can jump to the page in this function You can also write like this
Using ajax to call itself is wrong, so the front-end page will not jump. If you don’t believe me, type out the data and status in the ajax callback function to see what the result is
Jumping can be done on both the front and back ends. If you use ajax, it means you want to receive things from the back end and not let it control the page jump. If you want to control the back end, just use location.href
Ajax requests will not jump in the background code because asynchronous work has been performed. After executing your background code, the content in your Exit(){...} method will be returned to your front-end Ajax The function(data,status) method exists in data. If you want to jump: use it in the method body
This is an ajax request. The ajax request page will not jump.
Why don’t you just use a normal request if you log out?
You just sent an ajax request on the front end instead of a page jump.
Either let the backend return json data, and the frontend uses js to jump to the landing page according to its content;
or the frontend jumps directly to the target address, and let the backend redirect to the landing page.
Control page jump after ajax returns results:
The return data of the ajax request will be processed in the return function function(data, status). You can jump to the page in this function
You can also write like this
Using ajax to call itself is wrong, so the front-end page will not jump. If you don’t believe me, type out the data and status in the ajax callback function to see what the result is
Jumping can be done on both the front and back ends. If you use ajax, it means you want to receive things from the back end and not let it control the page jump. If you want to control the back end, just use location.href
Ajax requests will not jump in the background code because asynchronous work has been performed. After executing your background code, the content in your
Exit(){...} method will be returned to your front-end Ajax The
function(data,status)
method exists in data.If you want to jump: use it in the method body
Did you not configure the view resolver