var d = new Date();
curr_month = d.getMonth();
curr_date = d.getDate();
curr_year = d.getYear();
Obviously there's something fundamentally wrong here but it's a really simple concept. I want to be able to call a function (whether it's with "body onload" or some other call method). I tried messing with "return curr_date" (as well as the other variables) or with declaring curr_date (and the other variables) before the function, but can't figure it out. I've read a bunch of tutorials but just can't seem to nail down this specific question. Please help. I'm sure it's super easy.
P.S. If i run the series of statements outside of the function either within script tags either in the head or body it obviously works and I'm aware of that option but I'd really like to know how to accomplish this with a function. Thanks!