Both are the global functions of JavaScript.
(Come on Wscschool)
Escape
The escape () function encodes the string so that it can be read on all computers.
Hints and Notes
tip: You can use Unescape () to decode an escape () encoded string.
toGMTString:
Definition and usage
The toGMTString () method converts a Date object to a string based on Greenwich mean GMT (GMT) and returns the result.
Grammar
Dateobject.togmtstring ()
return value
The string representation of the Dateobject. This date is converted from the local time zone to the GMT time zone before being converted to a string.
Example 1
In this example, we will convert today's date to a (based on GMT) string:
<script type= "Text/javascript" >var d = new Date () document.write (d.togmtstring ()) </script>
Output:
Thu, Oct 05:41:45 GMT
prompt () method:
Definition and usage
The prompt () method is used to display a dialog box that prompts the user for input.
Grammar
Prompt (Text,defaulttext)
Parameters |
Description |
Text |
Optional. The plain text to display in the dialog box (instead of the HTML-formatted text). |
DefaultText |
Optional. The default input text. |
Description
Returns NULL if the user clicks the Cancel button of the prompt box. If the user clicks the Confirm button, the text that is currently displayed in the input field is returned.
It will block all user input to the browser until the user clicks the OK button or the Cancel button to close the dialog box. When prompt () is called, execution of the JavaScript code is paused, and the next statement is not executed until the user responds.
650) this.width=650; "Src=" https://s2.51cto.com/wyfs02/M00/A6/FF/wKioL1nfA1jx6ZLEAAGf3slQbCY663.png-wh_500x0-wm_ 3-wmp_4-s_1882269500.png "title=" image 1.png "alt=" Wkiol1nfa1jx6zleaagf3slqbcy663.png-wh_50 "/>
This article is from the "Jianbo" blog, make sure to keep this source http://jianboli.blog.51cto.com/12075002/1971692
JavaScript Objects Escape and toGMTString