Week3-Javascript Exercise – Milly Cai

the link

https://imanas.shanghai.nyu.edu/~yc2966/week03_js_exercise/index.html

The screenshot for the result

  

The code

html&js

CSS part

The problem met in the process

In the beginning, I’ve got in the problem with the border of the bottom sentence” it’s a dancing cat!”. The border didn’t show whatever I did with the getElemetById,  getElementsByClassName or even change the setting of the border… With the google developer tool, I notice what’s strange is that the area of the bottom text box which I set to contain the paragraph almost cover the whole html page. I’ve been troubled in this for a long time and cannot figure out the reason. Luckily, with the help of Cindy, I delete some useless properties such as display: flex and float for each box, and set the style of the border before I change the color of it in js. It finally works! As I don’t have much experience with coding before, this exercise does help me to learn more about the syntax and ways that the codes follow.

One Reply to “Week3-Javascript Exercise – Milly Cai”

Leave a Reply