03 2014 档案

摘要:最近需要在前台对编辑器生成的html代码做处理,需要进行编码,考虑到js没有直接对html编码的支持,看了下jQuery的实现,发现真是超级简单呀,顺便记录一下,需要的时候可以参考一下。```function htmlEncode(value){ if (value) { return jQuery('').text(value).html(); } else { return ''; }} function htmlDecode(value) { if (value) { return $('').html(value).te... 阅读全文
posted @ 2014-03-19 16:43 StanZhai 阅读(12014) 评论(0) 推荐(0) 编辑
摘要:"); background-size: contain; background-repeat: no-repeat; background-position: bottom;}.octicon-link:before{ content:'\a0';}body h1,body h2,body h3,body h4,body h5,body h6{ margin:1em 0 15px; padding:0; font-weight:bold; line-height:1.7; cursor:text; position:relative}body h1 .octicon 阅读全文
posted @ 2014-03-14 10:33 StanZhai 阅读(4923) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示