Page 1/5 of some useful and necessary small script code

Source: Internet
Author: User

Script 1: automatically play audio after entering the home page
<Embed src = "PNM: // 10.13.31.90 /~ Kayvin/mihunji. rm "hidden = true autostart = true loop = true> Script 2: when you enter the home page, you can click
<SCRIPT>
Self. moveTo (0, 0)
Self. resizeTo (screen. availwidth, screen. availheight)
</SCRIPT>

Script 3: displays the current time script

<Script language = VBScript> document. Write now </SCRIPT>

Script 4: displays the last modified time script.

<SCRIPT> document. Write (document. lastmodified) </SCRIPT>

Script 5: set as homepage, add as favorites, add to channel, start Outlook mail

<A style = "cursor: hand"
Onclick = "This. style. Behavior =" URL (# default # homepage )";
This. setHomePage (http://jb51.net/); ">"> set to home </a>

<A style = "cursor: hand"
Onclick = "window. External. AddFavorite (location. href, document. Title);"> Add to favorites </a>

<A href = javascript: window. External. addchannel ("Typhoon. CDF")> Add channel </a>
<A href = douxy001@gmail.com> contact me </a>

Script 6: the current time is dynamically displayed in the status bar.

<SCRIPT>
Function see (){
Window. setTimeout ("see ()", 1000 );
Today = new date ();
Self. Status = today. tostring ();
}
</SCRIPT>
<Body onload = see ()>

Script 7: Close the window script

<A href = javascript: Close ()> [close the window] </a>

Script 8: press the F12 key and return directly to the homepage.

<SCRIPT> function look (){
If (event. keycode = 123) {document. Location. href = http: // 10.13.31.90 /~ Kayvin /}
}
If (document. onkeydown = NULL)
{Document. onkeydown = Look}
</SCRIPT>

Script 9: backward, refresh, and forward

<Input type = button value = backward onclick = history. Go (-1)>

<Input type = button value = Refresh onclick = history. Go (-0)>

<Input type = button value = forward onclick = history. Go (+ 1)>

Script 10: set the time to pop-up window, 4000 = 4 seconds, of course, you can customize

<SCRIPT> function L ()
{
Window. Open ("10.13.31.90 /~ Kayvin/"," name "," width = 500, Height = 150, border = 0 ")
}
SetTimeout ("L ()", 4000)

</SCRIPT>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.