Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Trending News
Javascript html??? Please Help...?
Here was the instruction:
1) The user will put a number from 1 to 12,,, and that will indicate the month.
2. ) The user will now input a number from 1 to 7,,,, and that will indicate the day(monday to sunday)..
3.) Then it will OUTPUT a CALENDAR... wth the starting day of the 2nd output...
does someone know how to make that on the HTML using JAVASCRIPT..
Please Help me....
Tnx!
5 Answers
- AQuestionMarkLv 71 decade agoFavorite Answer
1. build the input for day and month for accepting data, a button to call function to generate calendar, div for accepting innerHTML code from script.
2. build javascipt function of nesting loop, innerloop deal with rows, outerloop deal with columns as date run across columns, it's more frequent to change columns than rows
3. setup arrays for day and month in words, as accepting data as well as script use numbers only
4. set date according to input receive, and use getDate, getDay etc to build condition that locate the date number on the table
5. break table components and combine them with date data and incrementally store in a variable
6. add break for getting out of the loop if loop count > total number of days in a month
7. put the calender html code stored in the variable in 5. to div in body using innerHTML
8. style the table components to make it more presentable.
Here's a demo
http://www.freewebs.com/swhtam/YA/calenderMaker.ht... go to menu View, source for the complete code.
- 5 years ago
For a basic definition, HTML is hyper-text markup language and JavaScript is a scripting language that was released by Sun Microsystems. To be a little more specific- if you view the source code on a website which can be easily done with most browsers, the tags that are between the '<>' brackets are HTML tags. HTML is a basic language used to lay out website templates. JavaScript is a step above HTML. JavaScript's code gets away from tags and greatly resembles many object-based languages. Its one of a few scripting languages that are commonly used to spruce up a website and add many of those cool little effects that you see on most of today's websites. The bottom line - HTML is required to make a website, even a basic one, whereas JavaScript is used to make sites more complex.
- Anonymous1 decade ago
you can create a function that make a table with 7 rows using TR and TD html tags, and the calendar class to get the day of first date ..
- 1 decade ago
try to learn about using "Gregorian Calendar" in javascript... but i'm not sure how to display the calendar visually..
- How do you think about the answers? You can sign in to vote the answer.
- » pōпб§±ë® ¬Lv 41 decade ago
uhm... im not really a javascript person but there are sources out on the internet.
if this can help you, please click on the links below:
i hope this could help you though