Assignment 2 was a continuation of Assignment 1 but with a few crucial add-ons. The main installment to Assignment 2 was the inclusion of a login and registration page so that the user had to either sign in or register a new account before accessing their invoice. The login and registration information needed to be validated by ensuring that they met certain requirements and then stored in the user_data file to ensure that it could be accessed again.
As I didn’t keep track of inventory in assignment 1, that was something that I was able to learn in this assignment. I also learned the process of creating a login and registration page by utilizing forms, query strings, and the POST method to have the information passed through each page. It was also fascinating to learn how the username and passwords were stored on the server and how only certain pages could be accessed by going through another page first.
I did not work with a partner on this assignment as Professor Port advised that we should not.
To get help when I needed it, I often referred to the video lectures and recordings. I mostly needed help with getting the server to track inventory and I was able to ask a friend who showed me what they had done and I was able to understand what they did so that I could get my assignment to function properly. I also needed help with being able for my assignment to work properly on the class server as every time I tried to sign up to access the invoice, it would say that the user_data file could not be opened. I asked the class discord if anyone else was having this issue and fortunately, someone reminded me that I needed to change the permissions of my assignment and the user_data file on Cyberduck.
The development of this assignment was different than assignment #1 because it wasn’t too much coding that needed to be done for the new HTML pages but for the server that we had created. There were many different approaches in terms of determining when then the login and signup pages were checked and how the information was passed on along each page. Overall, this assignment had more of an emphasis on functionality than the aesthetics of the website.
I think I spent about 20% of my time thinking about how to do something, 30% writing and commenting on the code, and then 50% testing. I believe that I spent almost 50% of my time testing because the initial code would constantly have issues so I constantly needed to test and re-write the code. Also, testing took longer than writing the code because when I would change a little bit of code, I would spend time ensuring that everything else on the website still worked.
In terms of what worked well, I would say the invoice page worked well in terms of being able to make adjustments to keep track of inventory. Furthermore, the validation for the registration and login page seemed to work well although getting the notifications to show up had some issues. There were two things that come to mind when I think about what did not work well in my project. For one, I was unable to use the POST method at all for a couple of hours until I realized that there was an extra server file in my main directory that prevented me from doing so. Also looking at other code and trying to modify it without fully understanding it initially made it more difficult to get my assignment to function.
If I could go back in time and do things differently, I would have made sure that I focused on fixing Assignment 1 for the resubmission first rather than trying to start Assignment 2 and work on them simultaneously. Trying to fix both as they were both due on the same day was definitely not the best decision. Furthermore, I would have attempted to start things off in a more simple manner and do things one at a time. Trying to add a bunch of code at once made it much more confusing to navigate and organize. For Assignment 3, I need to label things as I go rather than label them all at the end. Also as always, I should have started earlier and asked for my help. I need to ask for help from the professor or TA when I need it.