In Need Of Template

Can someone send me a simple template of a bar or button legit anything in html that adds something to a database. I been struggling on this for a while.

Hey @PapayaDude!

You’ll need a backend to access a DB. Here’s an example Repl that uses Python Flask and Replit DB. Please note that this template is vulnerable to XSS attacks, which means that anyone can run JavaScript on it. You would have to probably use some regex to filter that out.

See the Replit DB docs for more.

2 Likes

Your template does work but I gotta ask where the data is being stored.

1 Like

The Replit DB. Since it’s a webserver, everyone gets the same copy of the website and not a “ghost fork”. Also, I’m currently working on a Node.js Express version if you prefer that over Python Flask.

1 Like

My whole idea is basically to create a forum for users to post on as well as a login and log out feature. Then once I get the login and logout feature I should be all good with databasing I believe. I tried using the autheriation tab but it would appear that it is unable to fetch profile pictures so I’m also a little bit stuck there as well.

1 Like

the node.js version doesnt seem to load

It’s not finished yet. Still trying to figure out how to use the Replit DB npm package and Express post requests.

1 Like

Thanks for all your help but I’m tired like crazy I most likely will cya around

1 Like