循环中的异步请求

I want to implement the status log in textarea feature in my WordPress plugin. So I have a PHP variable which constantly updates and I want it to be displayed in the textarea in the admin panel. I've tried to make a loop in JavaScript which asks server for changes of the variable every second, but as PHP is executing in blocking manner the server just ignores the request.

You can try create a function in your backend who gets all the information and return a HTML object and call this function using Javascript or whatever you wanna use for this call, after you get this html, just update the view.

Or if you prefer using Javascript, rather than returning a HTML, just return all data that you wanna show and update the view :D