Q:

continuously redirect console output onto web page using flask

I am new to flask, I am trying to write a web app that continuously redirects stdout to web page. 
For example:-
stdout:-
line1
line2 
line3
.....

Is there a way so that i can display the same on a web page each time a new line is written to stdout incrementally along with the previous content still being there ?

A:

If I remember correctly, you can return a string under a view function in flask for just basic stuff (i.e. "hello world"). 
If you capture the output of your script/function as a string, you should be able to simply return it under whatever view function is being called to present the page. 

