I'm new at programming, so it would be easier for me if you could explain what the code is doing too. But anyway, at a certain point in my Javascript, I want to make a button disappear and replace it with the words that were on the button before. I've tried looking at a few different other questions about things like this, but this one was too confusing, and I didn't understand it, and this one, didn't work for some reason. Can anyone help me?
Thanks
EDIT
Here is some of my HTML:
<div class="inside">
<form name="form" onsubmit="return false">
<button id="id1" class="buttonthird" name="Button1" onclick="myFunction1()">Button 1</button>
<button id="id2" class="buttonthird" name="Button2" onclick="myFunction2()">Button 2</button>
<button id="id3" class="buttonthird" name="Button3" onclick="myFunction3()">Button 3</button><br/>
<button id="id4" class="buttonthird" name="Button4" onclick="myFunction4()">Button 4</button>
<button id="id5" class="buttonthird" name="Button5" onclick="myFunction5()">Button 5</button>
<button id="id6" class="buttonthird" name="Button6" id="p2" onclick="myFunction6()">Button 6</button>
</form>
<h1 class="counter"> <span id="number">0</span> guesses</h1>
<div>