Tag:html

  • How to use block annotation in HTML

    Time:2020-12-1

    General comments in HTML: <! — XXXXXXXX — >, where XXXXXXXX is the comment content HTML block comment CSS <! – [if ie] > .<![endif]–> (<!–[if !IE]>||<![endif] Copy code The code is as follows: 1. <! — [if! Ie] > <! — except ie, it can be recognized as <! — <! [ENDIF] — >2. […]

  • PHP clear HTML code, space, carriage return newline function

    Time:2020-11-28

    Copy codeThe code is as follows: function DeleteHtml($str) { $str = trim($str); $str = strip_tags($str,””); $str = ereg_replace(“\t”,””,$str); $str = ereg_replace(“\r\n”,””,$str); $str = ereg_replace(“\r”,””,$str); $str = ereg_replace(“\n”,””,$str); $str = ereg_replace(“&nbsp;”,” “,$str); return trim($str); } This function can be extended and modified as needed.

  • HTML CSS JS implementation tab TAB example code

    Time:2020-11-25

    Copy code The code is as follows: <html xmlns=””> <head> <meta http-equiv=”Content-Type” content=”text/html; charset=gbk” /> <meta http-equiv=”Content-Language” content=”zh-CN” /> <meta name=”roots” content=”” /> <meta name=”Keywords” content=”” /> <meta name=”Description” content=”” /> <title></title> <style type=”text/css“> Body {font: “song style”; font- size:12px; }a:link,a:visited{font-size:12px;color:#666;text-decoration:none;} a:hover{color:#ff0000;text-decoration:underline;} #Tab{margin:0 auto;width:220px;border:1px solid #BCE2F3;} .Menubox{height:28px;border-bottom:1px solid #64B8E4;background:#E4F2FB;} .Menubox ul{list-style:none;margin:7px 40px;padding:0;position:absolute;} .Menubox ul li{float:left;background:#64B8E4;line-height:20px;display:block;cursor:pointer;width:65px;text-align:center;color:#fff;font-weight:bold;border-top:1px […]

  • The difference between BR and br / in HTML

    Time:2020-11-24

    answer from stackflow: Simply <br> is sufficient. The other forms are there for compatibility with XHTML; to make it possible to write the same code as XHTML, and have it also work as HTML. Some systems that generate HTML may be based on XML generators, and thus not have the ability to output just a […]

  • Common methods of adding, deleting, modifying and checking HTML DOM with JavaScript

    Time:2020-11-23

    This paper describes the common methods of adding, deleting, modifying and querying HTML DOM by JavaScript. For your reference, the details are as follows: First of all, JS can modify all elements and attributes in HTML. It can also change CSS style, and can listen to all events and respond. This note mainly records how […]

  • Making simple progress bar with HTML + CSS

    Time:2020-11-18

    1. HTML code Copy code The code is as follows: Experience value: <span><b style=”width:50px;”> </b></span> 2. CSS Style Copy code The code is as follows: .progress-bar, .progress-bar b{background: url(“/images/ico.png”) no-repeat scroll 0 0; display: block;} .progress-bar {background-position: 0 0; height: 15px;width: 430px;} .progress-bar b {background-position: 0 -17px; height: 12px;} enclosure:

  • HTML left and right layout sample code

    Time:2020-11-17

    css: Copy code The code is as follows: html,body{ margin:0px; padding:0px; height: 100%; } .headbg{ background: black; color: white; height:48px; } .userManagerAll{ height: 100%; width: 100%; } .leftside{ background: #E6E6E6; float: left; height: 100%; width: 200px; margin: 0px; overflow-y:auto; } .rightside{ background: white; height: 100%; width:100%; align:right; } html Copy code The code is as […]

  • HTML page loading and parsing process in detail

    Time:2020-11-15

    The order in which the browser loads and renders HTML 1. The order of IE download is from top to bottom, and the order of rendering is from top to bottom. Downloading and rendering are carried out at the same time. 2. When rendering to a certain part of the page, all the above parts […]

  • On the limit of ordinal number of OL element in HTML document

    Time:2020-11-9

    Generally speaking, it is unlikely to encounter a huge < ol > list in HTML documents. This article is just a technical discussion. I happened to run into this problem and tested it. The measured limit is [- 2147483648, 2147483647], that is [- 2 ^ 31 ~ 2 ^ 31 – 1] There are some […]

  • Two methods and precautions of adding script script in HTML

    Time:2020-11-8

    How to add < script > script in HTML: 1. You can add JavaScript code directly to HTML Copy code The code is as follows: <script type=”text/javascript”> //Javascript code</script> When the interpreter embeds < script > code, the processing of HTML pages will be temporarily stopped. 2. Add external JS file Copy code The code […]

  • HTML JavaScript select all / deselect all operation example code

    Time:2020-11-7

    Copy code The code is as follows: <html> <head> <meta http-equiv=”Content-Type” content=”text/html; charset=gb2312″ /> < title > Untitled Document<script type=”text/javascript” language=”javascript”> function selectAllDels() { var allCheckBoxs = document.getElementsByName(“preDelCheck”); var desc = document.getElementById(“allChecked”); var selectOrUnselect=false; for(var i = 0; i < allCheckBoxs.length; i ++ ) { if(allCheckBoxs[i].checked){ selectOrUnselect=true; break; } } if (selectOrUnselect) { _allUnchecked(allCheckBoxs); }else […]

  • How to deal with it ASP.NET The problem of HTML5 client routing fallback in core

    Time:2020-11-7

    preface You should all know that when we use client applications built by application frameworks such as angular, react and Vue, you will always handle HTML5 client routing, which will handle client routing to pages and components completely in the browser. Almost entirely in the browser HTML5 client-side routing works well on the client side, […]