Home > Web Front-end > HTML Tutorial > <small>标签在主流浏览器里不能文本缩进?_html/css_WEB-ITnose

<small>标签在主流浏览器里不能文本缩进?_html/css_WEB-ITnose

WBOY
Release: 2016-06-21 09:41:38
Original
968 people have browsed it

<?xml version="1.0" encoding="UTF-8" ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Insert title here</title><link href="css/style.css" rel="stylesheet" type="text/css"/></head><body>	<small>test small</small></body></html>
Copy after login


@CHARSET "UTF-8";small {	text-indent: -9999px;}
Copy after login


以上代码在chrome、firefox、ie8、ie9全失效,在ie6、ie7正常,请问是什么原因?


回复讨论(解决方案)

用于定义块级元素中第一个内容行的缩进。

small不是块级元素,你换成P试下,或者给small添加一个display:block;

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template