I'm currently trying to grab a string that a user would put in an HTML form, and set that equal to a variable in a python program after the 'search' button has been clicked. I'm using flask to run the html code just on localhost. How would I go about implementing this?
The code I have for the search bar so far is below.
<div class="input-group pl-2">
<input type="text" class="form-control" placeholder="Enter a string...">
<span class="input-group-btn pr-2">
<button class="btn btn-success" type="submit">
<span></span>Search
</button>
</span>
</div>