from flask import Flask, render_template, request, redirect, url_for app = Flask(__name__) @app.route('/', methods=['GET', 'POST']) def index(): if request.method == 'POST': bank_name = request.form['bank_name'] branch = request.form['branch'] latitude = request.form['latitude'] longitude = request.form['longitude'] address = request.form['address'] fee_document = request.files['fee_document'] # Save the uploaded file fee_document.save(f'uploads/{fee_document.filename}') # You can now process these details or store them in a database return redirect(url_for('success')) return render_template('index.html') @app.route('/success') def success(): return 'Property valuation request has been submitted successfully!' if __name__ == '__main__': app.run(debug=True)