How can I open two log files in one HTML page in Django?
Create a new view in Django
in the controller, import os
use lastLines = os.popen("tail /path/to/logFile").read()
show these listLines in the view
I have my two log files in my django root dir called apache.error.log and django.log. In my app/static folder I have the HTML file mylog.html. Now I want to view those log files inside that HTML page.
Is this possible? I want to view the last 20 lines of both files. basically something like tail -f, but inside the browser so that I can have my one tab always open for debugging.