Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialDaniel Dircz
1,347 PointsDeleting a Post
Hi! I've completed this course and I'm looking to learn more about flask by making this app more robust.
I am trying to make it so I can delete a post, similar to how you would click the "View" button to view a post. I have added a "Delete" button, and created a Delete_post route and function, but if someone could explain to me how I would actually delete the post, that would be great.
Thanks
1 Answer
Seth Reece
32,867 PointsUse the same route as your view except give it the method DELETE. That part I'm pretty sure on. Then in your function call delete() instead of select() on your database query.. Maybe... Something to try.