Jun-16-2020, 06:49 AM
(Jun-16-2020, 06:36 AM)card51shor Wrote: Why would I need variables in the HTML? I already have the data that I need in the variable "b" in python. I just want to print out the values for the users to see from the search.How would user "see" the result of the search - on the page (displayed using HTML template). They don't see what is printed in the terminal console on the server.
How would you display search result in the page - by passing variables when you render the tempalte. As the name indicates - it's a template - it has fixed part that looks the same for every search result and you have dynamic part - the search result itself. There should be placeholders/variables in the HTML template and you need to fill-in these placeholders by passing values when render the template
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs