码迷,mamicode.com
首页 > Web开发 > 详细

CSS-使整个页面上的全部元素可编辑

时间:2019-01-02 01:28:08      阅读:272      评论:0      收藏:0      [点我收藏+]

标签:inline   display   cte   tin   round   splay   lin   mil   org   

# [在线预览](https://jsfiddle.net/1010543618/6zu1gush/) ## 方法一 - 使用html的contenteditable属性: [HTML 5 全局 contenteditable 属性](http://www.w3school.com.cn/html5/att_global_contenteditable.asp) ## 方法二 - 使用css的user-modify属性: [-webkit-user-modify](http://css-infos.net/property/-webkit-user-modify) [-moz-user-modify](https://developer.mozilla.org/en-US/docs/Web/CSS/-moz-user-modify)(不知为何我测试的时候不好使) ```html

我来组成头部

Article heading

Lorem ipsum dolor sit amet, consectetur adipisicing elit. Donec a diam lectus. Set sit amet ipsum mauris. Maecenas congue ligula as quam viverra nec consectetur ant hendrerit. Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur.

subsection

Donec ut librero sed accu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipisicing elit. Aenean ut gravida lorem. Ut turpis felis, pulvinar a semper sed, adipiscing id dolor.

Pelientesque auctor nisi id magna consequat sagittis. Curabitur dapibus, enim sit amet elit pharetra tincidunt feugiat nist imperdiet. Ut convallis libero in urna ultrices accumsan. Donec sed odio eros.

Another subsection

Donec viverra mi quis quam pulvinar at malesuada arcu rhoncus. Cum soclis natoque penatibus et manis dis parturient montes, nascetur ridiculus mus. In rutrum accumsan ultricies. Mauris vitae nisi at sem facilisis semper ac in est.

Vivamus fermentum semper porta. Nunc diam velit, adipscing ut tristique vitae sagittis vel odio. Maecenas convallis ullamcorper ultricied. Curabitur ornare, ligula semper consectetur sagittis, nisi diam iaculis velit, is fringille sem nunc vet mi.

?Copyright来组成脚部
```

CSS-使整个页面上的全部元素可编辑

标签:inline   display   cte   tin   round   splay   lin   mil   org   

原文地址:https://www.cnblogs.com/jffun-blog/p/10206521.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!