Home > Back-end >  JavaScript program can fill in the blanks to a handsome boy
JavaScript program can fill in the blanks to a handsome boy

Time:09-18

1. The following code is to show the effect of what day is today, please fill out the code of the horizontal lines on,












The function getTime () {

Var time=

Var week=time. GetDay ();

var p1=document.getElementById("p1");

P1. The innerHTML="what day is it today" + week;

}






2. The effect of the code is click on the link below close this window, please fill out the code of the horizontal lines on,





<meta charset="utf-8" & gt;





<body>








3. The effect of the following code is a number in the text box input, add the number 5, prompt dialog box displayed, please fill out the code of the horizontal lines on,





<meta charset="utf-8" & gt;





<body>

Month: & lt; Input the id="month" type="text"/& gt;






Var=cha document. GetElementById (" query ");

Cha. Onclick=xianshi;

The function xianshi () {

Var num=document. GetElementById (" month "). The value;



Num=num + 5;

Alert (num);

}



  • Related