Tip: 8.23 fixed the bug in ie 7 display. Please download it again. Sorry for this!
Update instructions:
2007-08-23 11:50
1. Fixed the bug with misalignment of button text in IE7.0 (the source code has been updated, please download it again if you have downloaded it).
2. Modified some js program code. (The height of the pop-up box is calculated only when initialized)
2007-08-23 21:30
1. The component introduction has been improved. It turns out that there were no introductions of 5-7, and some friends may not have noticed it either. Make up here!
======================================================
A small component that the company needed to write some time ago to replace the default gray message component (alert/Confirm) of Windows 2000. Since the system developed by the company is mainly aimed at IE browser, the code started running ineffective under ff. Today, it is planned to share it. In order to avoid being bricked, it took nearly an hour to modify the code compatibility. It is currently running normally under ie6.0 and FF2.0. Other browsers have not tested it, and the company is in trouble, so it is too lazy to spend a lot of time to do this to meet most needs.
Component Introduction:
1. The calling method is secondaryly packaged, and now it is written into a class, and then the calling method is turned into several simple method calls, and there is no need to new when calling. Calling the method is clear and simple.
2. Compatible with IE6.0&&FF2.0.
3. Currently, three and four skins are provided, Vista, QQ, ExtBlue and BlackColl. If you are interested, you can modify the stylesheet file to define a new skin.
4. Provide four message types. These are message prompts, success information, error information, and inquiry information.
5. When the message box pops up, block other elements of the page, automatically hide the page select and select under the iframe (unlimited select hidden), and mask the iframe and other elements.
6. The page select control state remains in the original state when restoring the status of the page select control, that is, if the original select is hidden, the select remains in the hidden state after the message box pops up and closes, and only the original displayed select is displayed.
7. When the message component pops up, block the operation of the keyboard Tab key and space bar (prevent the keyboard from operating page elements). Press the Enter key as the "OK" button of the message component.
Introduction to use:
1. First introduce it in the page.
2. Then call the required message function:
(1)Alert(content,width,height,title,okFunc,cancelFunc)//Message prompt type
(2)SucceedInfo(....) //SucceedInfo Type
(3)ErrorInfo(...)//Error message type
(4)ConfirmInfo(..) //Ask message type
The parameters of the four methods are exactly the same:
content: The content to be displayed by the message component.
width: If the width of the message box is not set, please set null, and the width is adaptable.
height: If the height of the message box is not set, please set null, and the height is adaptable.
title: Message component title
okFunc: The name of the function executed when clicking the OK button.
CancelFunc: The name of the function executed when the cancel or close button is clicked.
View the demo: /test/ymPrompt/
Note: Due to the speed of the network space, the image may load slowly when opening the demo for the first time. Please open it and download the image later or download the source code to view the demo locally.
Source code download:
Local download
Update instructions:
2007-08-23 11:50
1. Fixed the bug with misalignment of button text in IE7.0 (the source code has been updated, please download it again if you have downloaded it).
2. Modified some js program code. (The height of the pop-up box is calculated only when initialized)
2007-08-23 21:30
1. The component introduction has been improved. It turns out that there were no introductions of 5-7, and some friends may not have noticed it either. Make up here!
======================================================
A small component that the company needed to write some time ago to replace the default gray message component (alert/Confirm) of Windows 2000. Since the system developed by the company is mainly aimed at IE browser, the code started running ineffective under ff. Today, it is planned to share it. In order to avoid being bricked, it took nearly an hour to modify the code compatibility. It is currently running normally under ie6.0 and FF2.0. Other browsers have not tested it, and the company is in trouble, so it is too lazy to spend a lot of time to do this to meet most needs.
Component Introduction:
1. The calling method is secondaryly packaged, and now it is written into a class, and then the calling method is turned into several simple method calls, and there is no need to new when calling. Calling the method is clear and simple.
2. Compatible with IE6.0&&FF2.0.
3. Currently, three and four skins are provided, Vista, QQ, ExtBlue and BlackColl. If you are interested, you can modify the stylesheet file to define a new skin.
4. Provide four message types. These are message prompts, success information, error information, and inquiry information.
5. When the message box pops up, block other elements of the page, automatically hide the page select and select under the iframe (unlimited select hidden), and mask the iframe and other elements.
6. The page select control state remains in the original state when restoring the status of the page select control, that is, if the original select is hidden, the select remains in the hidden state after the message box pops up and closes, and only the original displayed select is displayed.
7. When the message component pops up, block the operation of the keyboard Tab key and space bar (prevent the keyboard from operating page elements). Press the Enter key as the "OK" button of the message component.
Introduction to use:
1. First introduce it in the page.
2. Then call the required message function:
(1)Alert(content,width,height,title,okFunc,cancelFunc)//Message prompt type
(2)SucceedInfo(....) //SucceedInfo Type
(3)ErrorInfo(...)//Error message type
(4)ConfirmInfo(..) //Ask message type
The parameters of the four methods are exactly the same:
content: The content to be displayed by the message component.
width: If the width of the message box is not set, please set null, and the width is adaptable.
height: If the height of the message box is not set, please set null, and the height is adaptable.
title: Message component title
okFunc: The name of the function executed when clicking the OK button.
CancelFunc: The name of the function executed when the cancel or close button is clicked.
View the demo: /test/ymPrompt/
Note: Due to the speed of the network space, the image may load slowly when opening the demo for the first time. Please open it and download the image later or download the source code to view the demo locally.
Source code download:
Local download