HTML代码在线运行工具

刺骨的言语ヽ痛彻心扉 2022-04-24 05:08 1151阅读 0赞

HTML代码在线运行工具

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
  5. <title>网页HTML代码在线运行器-测试版</title>
  6. <link rel="icon" href="img/ico.ico" type="image/x-icon" />
  7. <style type="text/css">
  8. .dowap-top-bar .nav-top-bar {
  9. border-bottom:1px solid rgb(168,173,177);
  10. height:20px;
  11. top:2px;
  12. opacity:0.4;
  13. position:relative;
  14. padding:0px 20px;
  15. text-align:center;
  16. font-size:12px;
  17. }
  18. .dowap-top-bar {
  19. color:black;
  20. }
  21. .dowap-top-bar {
  22. left:0px;
  23. margin:0px auto;
  24. line-height:90%;
  25. }
  26. .logo{
  27. margin-bottom:5px;
  28. margin-top:-10px;
  29. width:100%;
  30. height:80px;}
  31. .Sub {
  32. border:1px solid rgb(197,226,242);
  33. background:url(img/but.gif) repeat-x scroll 50% top rgb(205,228,242);
  34. height:30px;
  35. margin-left:5px;
  36. cursor:pointer;
  37. margin-bottom:5px;
  38. width:90px;
  39. }
  40. .w970 {
  41. width:970px;
  42. overflow:hidden;
  43. margin:0 auto;
  44. margin-top:5px;
  45. }
  46. .copyright {
  47. color:rgb(102,102,102);
  48. text-align:center;
  49. font:12px Verdana,Arial,Tahoma;
  50. }
  51. .mapspage {
  52. background:url(img/bg_maplist.gif);
  53. }
  54. .map_list_add {
  55. margin:0;
  56. padding:0;
  57. font:14px "Microsoft YaHei","微软雅黑",tahoma,arial,"\5B8B\4F53";
  58. color: #999999;
  59. width:970px;
  60. line-height:25px;
  61. }
  62. div,ul,li,h3 {
  63. padding:0;
  64. margin:0;
  65. }
  66. .guide {
  67. width:970px;
  68. height:32px;
  69. margin:0 auto;
  70. padding:10px 5px 0;
  71. line-height:32px;
  72. font-size:14px;
  73. }
  74. .sitemap {
  75. width:970px;
  76. margin:0 auto;
  77. }
  78. .sitemap_title {
  79. padding:0 5px;
  80. }
  81. .sitemap_title h3 {
  82. font-size:18px;
  83. color:#4d4d4d;
  84. font-family:"Microsoft YaHei";
  85. line-height:5px;
  86. margin:15px 0 10px;
  87. }
  88. .sitemap_list {
  89. padding:10px;
  90. background-color:#fff;
  91. border:1px solid #f8f8f8;
  92. border-color:#dedcdd #c9c7c8 #c9c7c8;
  93. padding:12px;
  94. top:0;
  95. left:40%;
  96. -webkit-transition:all 0.3s;
  97. -moz-transition:all 0.3s;
  98. -o-transition:all 0.3s;
  99. -ms-transition:all 0.3s;
  100. transition:all 0.3s;
  101. box-shadow:0 1px 3px rgba(0,0,0,.2);
  102. -moz-box-shadow:0 1px 3px rgba(0,0,0,.2);
  103. -webkit-box-shadow:0 1px 3px rgba(0,0,0,.2)
  104. }
  105. .sitemap_list li {
  106. width:100px;
  107. height:24px;
  108. line-height:10px;
  109. float:left;
  110. font-size:14px;
  111. color:#999;
  112. list-style-type:none;
  113. }
  114. .sitemap_list li a {
  115. padding:0 2px;
  116. }
  117. .sitemap_list li a:hover {
  118. background:#42a8d7;
  119. color:#fff;
  120. }
  121. .clearfix:after {
  122. content:".";
  123. display:block;
  124. height:0;
  125. clear:both;
  126. visibility:hidden;
  127. }
  128. /* Hides from IE-mac \*/
  129. * html .clearfix {
  130. height:1%;
  131. }
  132. .clearfix {
  133. display:block;
  134. }
  135. a {
  136. color:#4d4d4d;
  137. text-decoration:none;
  138. }
  139. a:visited {
  140. text-decoration:none;
  141. }
  142. a:hover {
  143. color:#04aeda;
  144. text-decoration:underline;
  145. }
  146. a:active {
  147. color:#04aeda;
  148. }
  149. </style>
  150. <script type="text/javascript">
  151. function AddFavorite(sURL, sTitle) {
  152. try {
  153. window.external.addFavorite(sURL, sTitle);
  154. } catch(e) {
  155. try {
  156. window.sidebar.addPanel(sTitle, sURL, "");
  157. } catch(e) {
  158. alert("加入收藏失败,请使用 Ctrl+D 进行添加");
  159. }
  160. }
  161. }
  162. </script>
  163. </head>
  164. <body class="mapspage">
  165. <div class="dowap-top-bar">
  166. <div class="bg-top-bar">
  167. </div>
  168. <div class="nav-top-bar">
  169. <span>
  170. 如果您喜欢本工具,请
  171. <a href="javascript:void(0)" onclick="AddFavorite(document.title,window.location)"
  172. >
  173. 加入收藏
  174. </a>
  175. </span>
  176. </div>
  177. </div>
  178. <div class="w970">
  179. <div class="logo">
  180. <p>
  181. <a href="http://tools.5axxw.com" target="_blank"><img src="img/tool_logo.png" alt="返回工具首页" title="返回工具首页" width="131" height="73" border="0" /></a>
  182. <a href="http://www.5axxw.com" target="_blank"><img src="img/logo.png" alt="我爱学习网首页" title="我爱学习网 首页" width="155" height="56" border="0" /></a>
  183. </p>
  184. </div>
  185. <div class="map_list_add">
  186. <div class="sitemap">
  187. <div class="sitemap_list clearfix">
  188. <ul>
  189. <span style="color:#666666;font-size:16px;">
  190. 工具介绍: </span>
  191. 网页HTML代码在线运行器-测试版 ,本工具可以在线可视化编辑HTML代码,并且可以在线运行测试。请在正确的位置填写好网页代码,点击下边的【运行】按钮即可在线测试运行代码,点击【保存】按钮即可保存当前代码,简单、方便、快捷操作html代码。
  192. </ul>
  193. </div>
  194. </div>
  195. <br>
  196. <div>
  197. <textarea name="content" id="content" style="width:960px;height:400px;visibility:visible;">
  198. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  199. <html xmlns="http://www.w3.org/1999/xhtml">
  200. <head>
  201. <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
  202. <title>这里填写标题</title>
  203. <meta name="keywords" content="这里填写关键词" />
  204. <meta name="description" content="这里填写说明内容" />
  205. <script language="JavaScript" type="text/javascript">
  206. <!--JS代码位置-->
  207. </script>
  208. <style type="text/css">
  209. <!--CSS样式代码位置-->
  210. </style>
  211. </head>
  212. <body>
  213. 这里填写HTML代码
  214. </body>
  215. </html>
  216. </textarea>
  217. <div class="WSt1" style=" text-align:center">
  218. <br>
  219. <input class="Sub" type="button" name="Submit" value="运行代码" onclick="runCode('content')"
  220. />
  221. <input class="Sub" type="button" name="Submit2" value="保存代码" onclick="saveCode('content')"
  222. />
  223. </div>
  224. <script type="text/javascript">
  225. var lang = new Array();
  226. var userAgent = navigator.userAgent.toLowerCase();
  227. var is_opera = userAgent.indexOf('opera') != -1 && opera.version();
  228. var is_moz = (navigator.product == 'Gecko') && userAgent.substr(userAgent.indexOf('firefox') + 8, 3);
  229. var is_ie = (userAgent.indexOf('msie') != -1 && !is_opera) && userAgent.substr(userAgent.indexOf('msie') + 5, 3);
  230. Array.prototype.push = function(value) {
  231. this[this.length] = value;
  232. return this.length;
  233. }
  234. function $(objname) {
  235. return document.getElementById(objname);
  236. }
  237. function runCode(objname) {
  238. var winname = window.open('', "_blank", '');
  239. var obj = $(objname);
  240. winname.document.open('text/html', 'replace');
  241. winname.opener = null // 防止代码对论谈页面修改
  242. winname.document.write(obj.value);
  243. winname.document.close();
  244. }
  245. function saveCode(objname) {
  246. var winname = window.open('', '_blank', 'top=10000');
  247. winname.document.open('text/html', 'replace');
  248. var obj = $(objname);
  249. winname.document.write(obj.value);
  250. winname.document.execCommand('saveas', '', 'code.htm');
  251. winname.close();
  252. }
  253. </script>
  254. </div>
  255. </div>
  256. <br>
  257. <script type="text/javascript">
  258. var cpro_id = "u1275234";
  259. </script>
  260. <script type="text/javascript" src="//cpro.baidustatic.com/cpro/ui/c.js"></script>
  261. <div style="width:100%; border-bottom:1px solid #D9D9D9">
  262. <br>
  263. </div>
  264. <div class="copyright">
  265. <p>
  266. Copyright @
  267. <a href="http://www.5axxw.com" target="_blank">
  268. 我爱学习网
  269. </a>
  270. © 2008-2013
  271. <a href="http://www.5axxw.com" target="_blank">
  272. 5axxw Inc.
  273. </a>
  274. </p>
  275. <p>
  276. 法律声明 违版必究 资料版权 作者所有
  277. </p>
  278. <script type="text/javascript">
  279. var _bdhmProtocol = (("https:" == document.location.protocol) ? " https://" : " http://");
  280. document.write(unescape("%3Cscript src='" + _bdhmProtocol + "hm.baidu.com/h.js%3F9f604f900f5e9600424a4d1f9c67ea0c' type='text/javascript'%3E%3C/script%3E"));
  281. </script>
  282. </div>
  283. </div>
  284. </body>
  285. </html>

http://tools.5axxw.com/web/web\_run.html

posted @ 2019-01-21 15:08 波霸38 阅读( …) 评论( …) 编辑 收藏

发表评论

表情:
评论列表 (有 0 条评论,1151人围观)

还没有评论,来说两句吧...

相关阅读