I am creating a website which scrapes data from a site and displays that data in my site. I used selenium for scraping and this is purely written in python which converts scraped data to JSON. I used Javascript to fetch data from JSON and display it in HTML.
Now there are two things what I want to ask.
Firstly, how can I run that python file in web browser via web hosting.
Secondly, what I want is that every day my Javascript code run that python file so that whenever website is updated, the updated data is displayed in my website also.
Can anyone guide me how I can run Python file from Javascript. I also viewed Brython but it doesn't run my python(.py). Here's how I used Brython
These are the js files imported in head
<script src="/brython.js"></script>
<script src="/brython_stdlib.js></script>
And here in body tag I give reference to my python file
<body onload="brython()">
<script type="text/python" src="webScrapper.py">
</body>
But nothing happens.
Hope my question is clear. Thanks in advance for your brainstorming ideas