We all have those days where we're doubting ourselves and everything seems so difficult and practically impossible. For me, that was yesterday. When I was trying my best to follow along with the bootcamp's Javascript Tic-Tac-Toe video. I kept thinking to myself, how could I ever come up with this on my own? There are functions within functions and yet more functions everywhere! It's on those days that I particularly need the Codenewbie for some inspiration. I found out about this most adorable CSS game. Flexbox Froggy is now my new favourite game. It's a great way to kill time and just take your mind off impossible functions. You use CSS to move the little froggies to their lilypads. It reminds me of another game I love- Hoppers. Many an hour has been spent playing that game as well. <3 <3 <3
A student wanted to create several tables with foreign keys linking them. He was placing the forms all over the place and that just didn't seem to make sense to me. I suggested that he link all the forms to one main registration page, and while he worked on it, I came up with my own solution that I feel rather proud of. Though I'm well aware it is a very simple solution. views.py def register (request): # form for team formteam = TeamForm(request.POST or None ) if formteam.is_valid(): formteam.save() return redirect( 'registerForTeam' ) else : print (formteam.errors) formteam = TeamForm() # form for coach formcoaches = CoachesForm(request.POST or None ) if formcoaches.is_valid(): formcoaches.save() return redirect( 'registerForTeam' ) else : print (formcoaches.errors) formcoaches = CoachesForm() # form for player formplayer = PlayersForm(request.POST or None ...

Comments
Post a Comment