📄 test.php
字号:
<?php
echo "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd>\r\n<html>\r\n<head>\r\n\t<meta http-equiv=\"content-script-type\" content=\"text/javascript\">\r\n\t<meta http-equiv=\"content-type\" content=\"text/html; charset=windows-1252\">\r\n\t<title>Slider Bar Form Element</title>\r\n";
echo "<s";
echo "tyle type=\"text/css\">\r\n\tbody{\r\n\t\tmargin-left: 0px;\r\n\t\tmargin-top: 0px;\r\n\t\tmargin-right: 0px;\r\n\t\tmargin-bottom: 0px;\r\n\t\tpadding-left:10px\r\n\t}\r\n\r\n\r\n #panelDiv {\r\n position:relative; \r\n height: 300px; \r\n width: 700px;\r\n top:10px; \r\n left:10px; \r\n border:0px solid #333333;\r\n background-color: #f7f7f7;\r\n }\r\n\r\n #handleDiv {\r\n position: abs";
echo "olute; \r\n bottom:0px; \r\n right: 0px; \r\n width:10px; \r\n height:10px;\r\n background-color:;\r\n font-size: 1px;\r\n }\r\n\r\n #theimage {\r\n position:absolute;top:10px;left:10px;\r\n }\r\n\r\n.move {\r\n\theight: 21px;\r\n\tbackground: #f4f4ee url(/images/workflow/slider/bar_end.png) no-repeat 0 8px;\r\n\tcursor: hand !important;\r\n\tcursor: pointer;\r\n}\r\n.move .move2 {";
echo "\r\n\tmargin: 0 1px 0 2px;\r\n\theight: 21px;\r\n\tbackground: #fff url(/images/workflow/slider/bar_repeat.png) repeat-x 0 8px;\r\n\tcursor: hand !important;\r\n\tcursor: pointer;\r\n}\r\n\r\n.move2ondrag {\r\n\tmargin: 0 1px 0 2px;\r\n height: 21px;\r\n cursor: hand !important;\r\n cursor: pointer;\r\n\tbackground: #fff url(/images/workflow/slider/bar_repeat_hover.png) repeat-x 0 8px;\r\n}\r\n\r\n.move .slider {\r\n";
echo "\tmargin-left: 0;\r\n\tmargin-top: -21px;\r\n\tmargin-right: -11px;\r\n\twidth: 11px;\r\n\theight: 21px;\r\n\tbackground: #f4f4ee url(/images/workflow/slider/slider.png) no-repeat 0 0;\r\n\tcursor: hand !important;\r\n\tcursor: pointer;\r\n}\r\n\r\n.sliderondrag {\r\n margin-left: 0;\r\n margin-top: -21px;\r\n margin-right: -11px;\r\n width: 11px;\r\n height: 21px;\r\n background: #f4f4ee url(/i";
echo "mages/workflow/slider/slider_hover.png) no-repeat 0 0;\r\n cursor: hand !important;\r\n cursor: pointer;\r\n}\r\n\r\n</style>\t\r\n\t\r\n\t\r\n\t";
echo "<s";
echo "cript type=\"text/javascript\" src=\"/inc/slider/slider.js\"></script>\r\n\t";
echo "<s";
echo "cript type=\"text/javascript\">\r\n\r\n\t\t\t\r\n\r\n\twindow.onload = function() {\r\n\t\t// first\r\n\t\tvar el = document.getElementById(\"speed\");\r\n\t\tel.onDragStart = function() {\r\n\t\t\tin_elem = document.getElementById('speedin').className = \"move2ondrag\";\r\n\t\t}\r\n\t\tel.onDrag = function() {\r\n\t\t\tvar value_elem = document.getElementById('speed_value');\r\n\t\t\tvalue_elem.value = Math.round(Number(this.value));\r\n\t\t};\r\n\t\tel.on";
echo "DragStop = function() {\r\n\t\t\tin_elem = document.getElementById('speedin').className = \"move2\";\r\n\t\t}\r\n\t\tform_slider(el, '100');\r\n\r\n\t\t// second\r\n\t\tvar el = document.getElementById(\"speed2\");\r\n\t\tel.onDragStart = function() {\r\n\t\t\tin_elem = document.getElementById('speed2in').className = \"move2ondrag\";\r\n\t\t\tin_elem = document.getElementById('speed2').className = \"sliderondrag\";\r\n\t\t}\r\n\t\tel.onDrag = functi";
echo "on() {\r\n\t\t\tvar value_elem = document.getElementById('speed2_value');\r\n\t\t\tvalue_elem.innerHTML = Math.round(Number(this.value)) + '%';\r\n\t\t};\r\n\t\tel.onDragStop = function() {\r\n\t\t\tin_elem = document.getElementById('speed2in').className = \"move2\";\r\n\t\t\tin_elem = document.getElementById('speed2').className = \"slider\";\r\n\t\t}\r\n\t\tform_slider(el, '100');\r\n\t}\r\n\r\n\t</script>\r\n</head>\r\n\r\n<body>\r\n\t<h2>DOM Javascript S";
echo "lider Bar</h2>\r\n\t<p>Examples update a value inside a MySQL Database using the AJAX method when drag stops.</p>\r\n\t<label for=\"speed\">Speed</label><br />\r\n\t<input type=\"text\" value=\"20\" name=\"speed\" id=\"speed\" class=\"slider\" />\r\n\t<input type=\"text\" name=\"speed_value\" id=\"speed_value\" size=\"2\" value=\"20\" onkeyup=\"newValue(this.value, 'speed')\" />%\r\n\t<br />\r\n\t<br />\r\n\t<label for=\"speed\">Speed 2</label><br />\r\n\t<inp";
echo "ut type=\"text\" name=\"speed2\" id=\"speed2\" class=\"slider\" value=\"40\" maxlength=\"3\" />\r\n\t<div id=\"speed2_value\">40%</div>\r\n\r\n\t<p>View the <a href=\"index.phps\">source php code</a> (code for <a href=\"Sajax.phps\">Sajax.php</a>).</p>\r\n\t<p><a href=\"slider.zip\">Download Files</a> | <a href=\"\">Comments</a></p>\r\n\r\n</body>\r\n</html>\r\n";
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -