<! DOCTYPE html><Html><Head><Metahttp-equiv= "Content-type"Content= "text/html; Charset=utf-8 "><Title> Untitled Document </Title></Head><Body><Imgsrc= "Img/0.jpg"/><Imgsrc= "Img/0.jpg"/><Imgsrc= "Img/0.jpg"/><Imgsrc= "Img/0.jpg"/><Imgsrc= "Img/0.jpg"/><Imgsrc= "Img/0.jpg"/><ScriptSrc= "Js/myjs_file.js" ></Script><Script>var aimg = document.getelementsbytagname ("img");function showTime () {var myTime = new Date (); var iminutes = Mytime.getminutes (); var iseconds = Mytime.getseconds (); var str = Addzero (ihours) +addzero (iminutes) +addzero (iseconds); for (var i=0;i<str.length;i++) {aimg[i].src = "img/" + str.charat (i) + ". JPG "; }}setinterval (showTime, +); </script></body>< Span id= "Line34" ></HTML>
Ps:myjs_ File.js inside is actually a. Using the Trinocular operator to determine whether the number is greater than 10, when it is greater than 10 o'clock, the output is less than 10, and the number is preceded by 0;
Web front end of the day to learn a little JS knowledge of the fourth period