title: Flask: Showing print on website instead of console?
body: <p>is there a simple way to put every print command from a script on the webpage instead of the console of the server? I found out that you could use the command yield, but this only seems to work for loops, not for print commands.</p>
  
  <p>I tried this, but it couldn't work it out properly :/ <a href="https://stackoverflow.com/questions/15092961/how-to-continuously-display-python-output-in-a-webpage">How to continuously display Python output in a Webpage?</a></p>
  
  <pre><code>TypeError: can't concat bytes to str
  </code></pre>
  
  <p>My additional code is:</p>
  
  <pre><code>script=r'C:\scripts\module.py'
  # ...
  proc = subprocess.Popen(['script'],
  </code></pre>
  
  <p>when I write <code>[script]</code> instead of <code>['script']</code> I get a blank page which will load forever.</p>