I am trying to create a what is your horoscope program in javascript and will only output the last if statement, how do I fix it so it shows the words of what it is equal to? Code linked to JSFIDDLE
<body>
<center>
<p>To find your Horoscope click the button below!</p>
<input type='button' value='Click Me!' onclick='myHoroscope();' />
<p id="show"></p>
</center>
<script type="text/javascript">
function myHoroscope () {
confirm("In order to find your Horoscope you need to type in the month you were born correctly!")
var horoscope = prompt("What month were you born?")
if (age = "january")
{
document.getElementById('show').innerHTML = "January";
}
if (age = "february")
{
document.getElementById('show').innerHTML = "february";
}
if (age = "march")
{
document.getElementById('show').innerHTML = "march";
}
if (age = "april")
{
document.getElementById('show').innerHTML = "april";
}
if (age = "may")
{
document.getElementById('show').innerHTML = "may";
}
if (age = "june")
{
document.getElementById('show').innerHTML = "june";
}
if (age = "july")
{
document.getElementById('show').innerHTML = "july";
}
if (age = "august")
{
document.getElementById('show').innerHTML = "august";
}
if (age = "september")
{
document.getElementById('show').innerHTML = "september";
}
if (age = "october")
{
document.getElementById('show').innerHTML = "You are either the Libra 10/1 - 10/22 or Scorpio";
}
if (age = "november")
{
document.getElementById('show').innerHTML = "The Scorpio from 11/1 -11/23 or Sagittarius";
}
if (age = "december")
{
document.getElementById('show').innerHTML = "december";
}
}
</script>
</body>