This page describes my daily work on this website, what I did that day and how I did it.
Thursday Day 4 - 9/1/16 - About Me Page |
---|
What did you add to your website that the user will see? Today I made a side navbar, that can be pulled out from the side. A classmate sent me a link to a video that explained how to do it with the code attached, so I used that and adjusted it to fit my theme. I also decided on and made a consistent color scheme of dark slate grey and 2 different shades of lavender. The decision was the hardest part. I also put my pictures in the boxes, like I had planned, and centered these boxes, which is what I was having trouble with yesterday. Finally, I also put my name at the top and put it on the right side, so it can be seen (it couldn’t before because of the navbar tab). What code did you add to your pages? Break it down into explainable chunks and include the explanations of what it does and how. I used a line break (br) to make space between my boxes, and put the pictures further down so that the text was all together. I used a divider (div) around each of my tables, I think to put the pictures into the boxes, and to be able to center the boxes. I also made the pop out menu bar, but it has a really, really long code. |
Tuesday Day 5 - 9/2/16 - Hardware Plan |
---|
What did you add to your website that the user will see? Today I didn't add anything to my website, but I worked on and finished the hardware plan. To do this, I had to research and take notes about different parts of a computer, including the Motherboard, CPU, RAM, and Hard Drive. What code did you add to your pages? Break it down into explainable chunks and include the explanations of what it does and how. Because I didn't add any code, this question isn't relevant, but you can look at the Hardware Page to see what I learned. |
Tuesday Day 6 - 9/6/16 - Hardware Page |
---|
What did you add to your website that the user will see? Text, images, positions, borders, colors, etc. Be specific. I made everything for my hardware page, including boxes that each subject goes in. What code did you add to your pages? Break it down into explainable chunks and include the explanations of what it does and how. First, I made a new file for the hardware page by choosing "HTML file" in the "New from Template" part of "File". I renamed this "hardware.html" so I knew what page I was using. I also had to link this page in the navbar of the About Me page. Next, I copied and pasted the style and navbar parts of my about me page file into the new hardware.html file. I also copied the format I had used for the About Me page, which was using tables, which seemed to work, but I later learned that these don't work well as a format, which is when you are supposed to use "divs" instead. However, there didn't seem to be any problems, so I used tables anyway, also because I still didn't know about divs. When I put pictures in, I used (width="60%”) to make them smaller, and I experimented with the width and height to see how they'd best fit. I used (style="margin-right:5px") to add space between the words and the border, which took a long time to figure out, but it makes the overall page look less cramped and just better. A problem I faced was that I used tables to make this page, which was confusing because the teacher didn’t know how to navigate using tables as well as with using divs, so now I have to learn how divs work. |
Thursday Day 4 - 9/1/16 - About Me Page |
---|
What did you add to your website that the user will see? Today I made a side navbar, that can be pulled out from the side. A classmate sent me a link to a video that explained how to do it with the code attached, so I used that and adjusted it to fit my theme. I also decided on and made a consistent color scheme of dark slate grey and 2 different shades of lavender. The decision was the one of the hardest parts. I also put my pictures in the boxes, like I had planned, and centered these boxes, which is what I was having trouble with yesterday. Finally, I also put my name at the top and put it on the right side, so it can be seen (it couldn’t before because of the navbar tab). What code did you add to your pages? Break it down into explainable chunks and include the explanations of what it does and how. I used a line break (br) to make space between my boxes, and put the pictures further down so that the text was all together. I used a divider (div) around each of my tables, I think to put the pictures into the boxes, and to be able to center the boxes. I also made the pop out menu bar, but it has a really, really long code. |
HTML Section |
---|
The HTML section of the calculator page is where I made the boxes, operations dropdown, answer button, and where the answers are shown. The boxes are where the numbers are put in, the operations dropdown is where the operation options are shown. These include addition, subtraction, multiplication, division, to the power of, and module, which means the remainder. This page is also linked to the Calculator Javascript page. |
Javascript Section |
---|
The Javascript section of the calculator page is what makes the calculator actully work, because right now, on the actual page it looks like there's a working calculator, but it wouldn't actually work. |
HTML Section |
---|
This code is 20 nearly identical images that include a common class, "card", common source, which is the image of the back of the card titled "blueCard.png", a common width of 100 pixels, an onclick, which we don't use, but is there because we were deciding on how to make the game from a number of different ways, and it was from a discarded way, and the not identical id, which starts at 0 and are each numbered. They are organized into 4 divs with each div containing 5 of the elements so that they are in 4 rows with 5 columns. |
Javascript Section |
---|
First, this code is a variable called cardsOpen with the number 0 in it. This is so that later we can count how many cards have been opened (showing the front) so that they can get turned back over if they're wrong. We need to know how many cards are opened because otherwise it won't know when to close the cards. The inside number will be replaced with one and two, when the first card is opened then the second is.
In this section of code, it has the variable cardsOpen, and it has ++, which means that when a card is clicked, the number in the variable increases by one. The reason it needs to increase by one is that in the next section it needs to see if the variable holds a number equal to or greater than 2 (cards open) so that it runs.
Finally, in this third section, there is another if else statement, which is inside the if statement from the last section. Its condition is that if the element ids of cards 1 and 2 are different, then it should run ANOTHER if statement inside that. The ids have to be different so that the cards can't just be clicked twice and technically have the same image, which would mean that it's right, because it of course has the same image as itself, but it's of the same card. Thus, it makes it so that two different cards have to be clicked in order to check if they're right. |