As I ask this question, I acknowledge that it may have been asked many times before. If I missed the answers due to my ignorance, I apologize.
I have a hosting plan that restricts me from installing Django, which provided a convenient way to set up a REST API with routing settings.
What I am seeking is the ability to call a Python function from JavaScript code using a get/post method (I am currently using AngularJs, but the process would be similar for an Ajax get/post).
Let's consider I have a JavaScript controller named 'Employee' and a view called 'CreateEmployee'.
From my JavaScript view, I can invoke my CreateEmployee() function on the JavaScript controller. My inquiry is how can I call a specific function, like def CreateEmployee(params...), in my .py file?
All my research has led me to making get/post requests to my .py file, but I haven't found resources explaining how to execute a particular function.
It is possible that I am struggling to comprehend the communication between Python and client/server. Having spent a significant amount of time coding on ASP.NET WebForms, the limitations imposed by the absence of frameworks like Django have left me at a standstill.
Thank you