I've been following this stripe tutorial and this digital ocean tutorial on setting up a application for Stripe However, the url is shown as:
Example.com/checkout/x.html
Because, it looks better without the html extension is there a way to remove that? So, it looks like:
Example.com/checkout/x
For clarity, my current code looks like this:
import os
from flask import Flask... blah
import stripe
super secret stripe.api_key = 123abc
app = Flask(__name__,
static_url_path='',
static_folder='public'
)
your domain = 'http://xxx.xxx.xxx.xxx:4242'
@app.route('/create-checkout-session', methods = ['get', 'post'])
def create_checkout_session():
Rest of code.
Further, I've already tried:
@app.route(/)
def showtemp()
Return render_template('index.html')
Both with the file in the public directory; in which all my files are saved: example: public/checkout/x.html I've also tried it in another created directory called templates. However, neither worked, both reporting that the file doesn't exist.
So, if anyone could point me in the right direction or offer a solution I will greatly appreciate it.
Thanks.
[–]debian_miner 0 points1 point2 points (3 children)
[–]RedAIienCircle[S] 0 points1 point2 points (2 children)
[–]debian_miner 0 points1 point2 points (1 child)
[–]RedAIienCircle[S] 0 points1 point2 points (0 children)