freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

網(wǎng)頁設(shè)計外文翻譯-在線瀏覽

2025-03-02 17:35本頁面
  

【正文】 { = (0, position) position = position + 1 if (position ) { position = 0 } (mymessage( ), 300)}DATES AND TIMESDates and times are often displayed on web pages to indicate when a page was last updated, when a page was loaded, or to display a countdown to a particular event. Displaying the date and time of the last update is a good practice to get in to for all of your pages because frequent updates are one sign of a quality site. The date/time stamp lets the viewer know how recent the information is and therefore provides one indication of validity. To display the date and time of the last update (the last time the document was saved) use the following one line inside of script tags: (This page last updated + ) To display the current time and date on a web page you must declare a variable of type Date ( var now = new Date). The variable can then be used to access various parts of the date and time including day of the week, month, day of the month, year, hours (in military time), minutes, and seconds. Assuming that now is the variable declared of type Date the following table describes how to access the parts of the date and time. Each of the function calls may be used in a statement to display the result. Table13 various parts of the Date type variableFunction CallDescription( ) Returns a number between 0 and 6 for the day of the week (Sunday is 0, Monday is 1,...) ( ) Returns a number between 0 and 11 for the month (January is 0, February is 1,...) ( ) Returns the number of the day in the month (1 31) ( ) Returns the four digit year ( ) Returns the number of hours on the clock (0 23) ( ) Returns the number of minutes on the clock (0 59) ( ) Returns the number of seconds on the clock (0 59) One way to convert the numbers for the month and day of week in to words is to use if statements. Using a lot of if statements is not the most efficient way to display the words, but it is the method that requires the least amount of programming knowledge. Examine the following example. Notice the condition that follows the word if is in parentheses and that a double equal sign is used for the parison. A single equal sign will actually make the condition true no matter what so January would always be displayed. if (( ) == 0) (January) The following function would display a working clock if your page contained a form called myform which contained a text box named mybox and the function was called using the onload event handler in the body tag. More code would need to be added to assure that the minutes and seconds always used two digits. function myclock( ){ var now = new Date (myclock( ),1000) }To display a countdown to a future date, you will need two variables of type new Date. One of them will need to be set to the date that you are targeting with your countdown. The declarations would look as follows if you were going to count down to New Year39。s!) INTERACTIVE FORMSForms can be used for a lot more than just submitting information through . Forms can be made to perform all sorts of actions when buttons are clicked.中文翻譯出處:使用JavaScript設(shè)計網(wǎng)頁THE BASICS基礎(chǔ)JAVASCRIPT uses a subset of the programming language JAVA to provide a high level of interactivity on a web page. JavaScript使用編程語言Java的一個子集在網(wǎng)頁上提供高層次的交互。JavaScripts may be located within the HTML code at the point in the page where they are to appear on the screen or they may be written using functions. JavaScript可能位于HTML代碼中他們在屏幕中出現(xiàn)的位置上,也可能用函數(shù)寫成。Whether the script is stored between the head tags or within the body of the HTML document, it must be enclosed in script ,它都必須包含在腳本標記。Following is an example of the script and ment tags:以下是一個腳本和注釋標簽的例子: script language=javascriptscript language=javascript!這里包含的JavaScript代碼///script !Include JavaScript Code Here///scriptBe aware that JavaScript is case sensitive...the difference between a working script and an error message can be one capital ,JavaScript是區(qū)分大小寫的...一個可運行腳本同錯誤消息的區(qū)別常常就在于一個大寫字母。Please note that the processing of the page will stop until the viewer responds to the alert ,直到用戶響應(yīng)警告框。In order to take full advantage of the features of these dialog boxes you must write more JavaScript code which can use the values that are returned by the dialog ,則必須編寫更多的JavaScript代碼,來使用這些對話返回的參數(shù)值。If the answer is OK then the variable named answer has a value of true and if the answer is Cancel then the variable named answer has a value of ,則以不同名字命名的變量會被賦予真值;如果答案是取消,則以不同名字命名的變量會被賦予假值。var answer = confirm (Are you sure you want to quit?)if (answer==true){()}var answer = confirm (Are you sure you want to quit?)if (answer==true){()}The following code will pop up a dialog box that asks the user to enter some sort of ,要求用戶輸入某些信息。The second set of quotation marks inside of the prompt statement make the contents of the text box blank when the dialog box is 。Window refers to the browser window and document refers to the page being ,而文檔是指顯示的頁面。In this next example, the navigator object is referenced in order to display the browser name
點擊復(fù)制文檔內(nèi)容
規(guī)章制度相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1