Is there a way of writing Python embedded in HTML like I do with PHP or JSP?
It is possible to run embed Python within a HTML document that can be executed at run time.
You can use python in your HTML code. You don't need to know javascript. PyScript is not just HTML only, it is more powerful, because of the rich and accessible ecosystem of Python libraries.
Use a template engine, such as:
The python wiki also has an article on this topic, with many more suggestions.
There is... But you're highly suggested to use a templating engine, or some other means of separating the presentation from the business layer.
There are some available that use python as the templating language, but it's nasty because python is sensitive to whitespace, so special syntax hacks have to be added.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With