ForumTechnical Corner ► Two Cans Website That ____ When You ____
Hi. We've made songs together. We've made currencies together. We've made a newsletter together. This time we're going to make a website together, and it will represent everything this website stands for.

This is made for people who are nerds and have knowledge of HTML, CSS, or JavaScript. If you meet this criterion but still do not understand the rules below, just send a message.

🟡 STATUS: Ready
The on-page code has been changed to reflect any additions, but the webpage has not been updated.
05:51 EST January 19 2023

The current code:
index.html
1  <!-- This code was created by the folks over at Two Cans and String
2  https://twocansandstring.com/forum/technical/12059/page1 -->
3  <!DOCTYPE html>
4  <html>
5    <head>
6      <title>Two Cans and String 2</title>
7      <link rel="stylesheet" href="./style.css" />
8    </head>
9    <body>
10     <h1>Two Cans and String</h1>
11     <h2>this is a subtitle</h2>
12     <h3>this is a subsubtitle</h3>
13     <h4>this is a subsubsubtitle</h4>
14     <br />
15     <button onclick="document.body.style.backgroundColor = 'black';">
16       Useful Button
17     </button>
18     <button
19       onclick="document.body.style.backgroundColor = '#634632'; document.querySelector('#horseimg').hidden = false;"
20     >
21       horse
22     </button>
23     <button>Less Useful Button</button>
24     <img
25       src="https://twocansandstring.com/uploads/drawn/35839.png"
26       alt="horse"
27       id="horseimg"
28       hidden
29     />
30     <button onclick="document.body.style.backgroundColor = '#ffffffff'; document.querySelector('#horseimg').hidden = true;">reset page</button>
31     <button><a href="https://twocansandstring.com/">Original Site</a></button>
32     <script>
33       window.onload = () => alert("horse");
34     </script>
35   </body>
36 </html>

style.css
1  * {
2    box-sizing: border-box;
3  }
4  
5  body {
6    font-family: "Comfortaa", sans-serif;
7  }
8  
9  h1 { 
10   color: #add8e6; 
11   text-align: center;
12 }

Please remember that I am one man that has to update this every time a new message is sent. If there is a backlog of messages (>=3) please don't add anymore for my own sake.

To insert a line of code, send a post formatted like this, where X is the line of code before what you're inserting, and Y is the line of code after what you're inserting (if you are editing a page other than index.html, state which one):
X  <head>
     <title>This is my cool webpage</title>
Y  </head>

If you are replacing something or inserting content inbetween an element, format it like this, replacing the X in - X with the line of code you are replacing:
- X <p></p>
+   <p>Look at me ma</p>

After an insertion or replacement, certain elements like <style>, <div>, or <script> will be given linebreaks to improve readability and made changing stuff around easier and less destructive.

You are only allowed to add one line at a time. Anything longer than that won't be considered, and something that would give an error or break the page will also be dismissed.

If there is a <style> tag, <script> tag, or any tag that uses another language, you are allowed to insert code in that designated language between it. For example, if someone added a <style> tag on line 4 and you wanted to make the background blue, you would send this:
- 4 <style></style>
+   <style>body { background: blue; }</style>
  
Here, I'll start things off.
3 <head>
    <title>Two Cans and String 2</title>
4 </head>
  
6<br>
7<button>Useless Button</button>
  
Your post is invalid. You added two lines and you aren't telling me where to insert anything. Reread the rules or if you're confused ask me about it.
  
Does this work?

+8 <br>
  
No. Reread the rules.
  

8 <br>
  
...What part about this do you not understand? Have you read the rules? Thoroughly? That isn't even close to valid. Not even close.
  
I HAVE! THIS MAKES NO SENSE! ALL I WANT TO DO IS PUT A BREAK TAG ON LINE EIGHT!
  

oh my fucking god

  
hoyle i dont understand either im sorry
  
Maybe this was just too good to be true.
  
No, the rules just need to be reworked
  
I am too fucking lazy to rewrite them and I feel like most people here don't know HTML anyways. Just tell me what you don't understand, otherwise I wouldn't know what to change.
  
I don't understand how to ADD A SINGLE LINE OF CODE
  
Elaborate?
  
All I am wanting to do is put a break tag underneath the header
  
7 <h1>Two Cans and String</h1>
       <br>
8   </body>
  
Okay, that makes sense
  
Thank god. It's been added now. I applaud you, Kylljoy.
  
Just doing my part.
  
i still dont get it and i am expert coder
  
prove it
  

8<br>
     <button>Useless Button</button>
9</body>
  
Can we make a stylesheet file?
  
Forum > Technical Corner > Two Cans Website That ____ When You ____