I want to check that my dummy.csv exist or not in my local system. If it exist then this Check Fraud Status will be displayed otherwise it won't. I don't want to use Javascript. If any solution relating to python jinja then please help me out.
And one more thing how to import os
in html page using jinja?
I had tried this:
layout.html
{% if os.path.exists('./static/userdata/dummy.csv') %}
<a class="nav-item nav-link" href="{{ url_for('checkfraudstatus') }}">Check Fraud Status</a>
{% endif %}
error
jinja2.exceptions.UndefinedError: 'os' is undefined