The Windows taskbar displays the cool web page !!!!!!!!!!!

Source: Internet
Author: User

The Windows taskbar displays the cool web page !!!!!!!!!!!
Author: lee1892 ----------- Organizer: lnboy

As we all know, the Windows taskbar can display a shortcut button bar called quicklaunch, or you can add a specified directory and display the buttons of all files in the directory.
Do you know that it can display the content of an HTML file? It does!
Can you imagine what this will do? Very interesting. Let's take a look.

Right-click the taskbar and choose toolbar> new toolbar ..
Javascript: window. Location. Replace ("file: // D:/toolbar/time/index.html ")
--------------------------------------------------------------------------------
(Here is an example of a file named index.html in the Directory D: \ Toolbar \ time. This file will be provided later). Java Script: window will appear on the taskbar. right-click and refresh the text, and the text such as server not found may appear. Right-click the text and refresh it. The title of the HTML file should appear, adjust the width of this column to see its content. During the refresh period, a dialog box such as permission restriction may pop up, always yes. Refresh twice. (A script error may be prompted during refresh. You just need to refresh it several times)

The following are the preceding HTML source files of time:
Code: -------------------------------------------------------------------------------- <! -- Time -->
<HTML>
<Head>
<Title> time </title>
<Style>
Body {border: 0; Background-color: buttonface; color: black; margin: 3px, 0, 0}
. Clocktxt {font-family: Arial; font-weight: normal; font-size: 8pt}
# Btnsd {border: 2px groove white; Background-color: buttonface; font-family: verdana; font-size: 9px}
</Style>
<Script language = "JavaScript">
// Clock script
VaR showclock;

Function Init (){
Showdate ()
Showclock = true;
}

Function showdate (){
// Edit refresh rate here
VaR refreshrate = 1000;

VaR clock = new date ()
VaR hours = clock. gethours ()
VaR minutes = clock. getminutes ()
VaR seconds = clock. getseconds ()

VaR DN = "am"
If (hours> 12 ){
DN = "PM"
Hours = hours-12
}

If (hours = 0) hours = 12
If (minutes <= 9) minutes = "0" + minutes
If (seconds <= 9) seconds = "0" + seconds

// Edit format here
Format = hours + ":" + minutes + ":" + seconds + "" + DN;

Time. innerhtml = format;

If (showclock = false) Time. innerhtml = "<input type = 'button 'value = 'sh. time' id = 'btnsd' Title = 'show time'>"
Else
SetTimeout ("showdate ()", refreshrate)
}
</SCRIPT>
</Head>
<Body scroll = "no" onLoad = "Init ()">
<Center>
<Font class = "clocktxt"> <span id = "time" style = "position: center;"> </span> </font>
</Body>
</Html>
In this way, you can see a time display in the taskbar.

OK. We already know how to display HTML files on the taskbar. Next, I want you to know how to drag it to the edge, that is, to drag the title to the desktop with a mouse, to a window, and then drag it to the edge of the screen, it becomes a sidebar. You can set whether to automatically hide and whether to always be at the top.

Before giving a few examples, let's talk about some tips for writing such HTML.
1. display the background color of the same color as the taskbar
Add in the

Code: ------------------------------------------------------------------------------ <style> body {border-width: 0; Background-color: buttonface;...} </style> response --------------------------------------------------------------------------------
In this way, when theme is changed, it will be replaced together.

2. Automatically refresh the page
In some cases, you may want to automatically refresh the webpage and add it to the Code: ------------------------------------------------------------------------------ <meta http-equiv = "refresh" content = "60"> response --------------------------------------------------------------------------------
The number of content should be seconds)

3. Disable the scroll bar.

Code: Response <body scroll = "no"> --------------------------------------------------------------------------------

4. Set page margins
Add it to the style setting of the body
Code: Optional margin --------------------------------------------------------------------------------

I almost forgot to say that my computer must be added to the taskbar. That is to say, each new one must start from scratch (right-click on the taskbar... drag to the desktop and then drag it to the edge). I don't know if you have to do the same.

The following is some sample code:

Example 1: Perpetual Calendar

Code: ---------------------------------------------------------------------------------- HTML quicklaunch ///

Calendar by lee1892
Original file from http://hohula.myetang.com/html/calendar.html

Java Script: window. Location. Replace ("file: // X:/.../calendar/index.html ")

You can change the rows 1246-1262 to hide or show some parts.
For example to hide part worldtime, change line 1246 and 1247
Original:
Worldtime. style. Visibility = 'visible '// 'hidd'
Worldtime. style. Position = 'relative '// 'absolute'
Change:
Worldtime. style. Visibility = 'hidd' // 'visible'
Worldtime. style. Position = 'absolute '// 'relative'
You must know the word after // is only comments in JS :)

Example 2: chinacnet real-time rolling news

Code: ---------------------------------------------------------------------------------- HTML quicklaunch ///

China News by lee1892

Java Script: window. Location. Replace ("file: // X: //.../Chinanews/index.html ")

You can change the news you want to show at line 41
Original:
<Script language = "JavaScript" src = "http://app0.china.com/freecode/out.php? Typeid
= 945 & num = 20 & t = No "> </SCRIPT>

The number after 'typeid' indicate the news 'catalog (see table below)
264 cultural fax page
1055 Education News Page
420 Stock Market News Page
567 Financial News
205 video focus page
764 medical news page
777 gender topics page
25 military comment page
64 Military News Page
167535 renewal page
945 Chinese news page
1007 social news page
1000 international news page
1024 important news page
1040 Chinese football news page
1221 NBA news page
1066 world tennis news page
1047 international football news page
154 technology news page
156 Internet news page
896 focus on news page
You shoshould also check page http://app0.china.com/freecode/freenews.php to see

Latest infomation.

You also change the number of news you want to show, locates at line 41 and 57
At line 41, the number after 'num', and at line 57 is the value of Variable

Newsitem. Change them to a same number which shocould be 10, 20, 30... 100.

Example 3: Weather online

Code: ---------------------------------------------------------------------------------- HTML quicklaunch ///

Weather by lee1892
Infomations from http://www.t7online.com/

Java Script: window. Location. Replace ("file: // X:/.../weather/index.html ")

You shoshould check you local city id from http://www.t7online.com/first, and then change Line 98
Original:
VaR mycityurl = "http://www.t7online.com/cgi-bin/citybild? Provider = Anwendung & wmo= 58362 & lang = cn"
Change number after 'wmo = 'to your local city id.

Example 4: Winamp Control

Code: ---------------------------------------------------------------------------------- HTML quicklaunch ///

Runbox by [kmr]

Java Script: window. Location. Replace ("file: // X: //... // htmlql/ampbar/index.html ")

A Winamp control. You need the winampcom plugin (http://www.adcock8.freeserve.co.uk) for the page to work properly.
Double-click the window to activate/desactivate the auto song info update .--------------------------------------------------------------------------------

This is not my own pleasure. The winampcom homepage provided by him is also changed to http://mysite.freeserve.com/johnadcock. it should not be supported.
Example 5: runbox: enter a command in the column to run. It is equivalent to the run dialog box function.

code: detail

RUN box








----------------------------------------------------------------------------

In fact, the address toolbar that comes with windows can be used. The reason for this example is to explain how to use HTML to startProgram, Huh

The last few words:

I want to talk about the immature examples I have made, but I just want to give you some ideas.

We know that adding vbs and js to HTML is very powerful (for example, for Windows Messenger, there is mapi, and we don't know if vbs can be called ?), There is also a fancy flash, you can even put flash in your own sidebar (such as a fun game, it becomes a real desktop game ).

There are many other things you can do. You must have more ideas or better implementation methods. Come to the discussion, even if it's just some ideas (maybe some experts know how to implement it ).

I am just a leader

--------------------------------------------------------------------------------
The above content by lnboy sort favorites, original post in http://bbs.et8.net/bbs/

Continue to read the awesome gameplay of displaying web pages on the Windows taskbar! The full text...

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.