This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 更新: | |
// 05.27: 1、保证回调执行顺序:error > ready > load;2、回调函数this指向img本身 | |
// 04-02: 1、增加图片完全加载后的回调 2、提高性能 | |
/** | |
* 图片头数据加载就绪事件 - 更快获取图片尺寸 | |
* @version 2011.05.27 | |
* @author TangBin | |
* @see http://www.planeart.cn/?p=1121 | |
* @param {String} 图片路径 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'jpeg_quality', create_function( '', 'return 100;' ) ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter('the_content', 'pirobox_gall_replace'); | |
function pirobox_gall_replace ($content) | |
{ | |
global $post; | |
$pattern = "/<img(.*?)src=('|\")([^>]*).(bmp|gif|jpeg|jpg|png)('|\")(.*?)>(.*?)>/i"; | |
$replacement = '<img$1src=$2$3.$4$5 class="img-responsive"$6>$7>'; | |
$content = preg_replace($pattern, $replacement, $content); | |
return $content; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!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>透明测试</title> | |
<style> | |
*{ | |
margin:0; | |
padding:0; | |
font-size:12px; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
// While you can edit this file, it's best to put your changes in | |
// "User/Preferences.sublime-settings", which overrides the settings in here. | |
// | |
// Settings may also be placed in file type specific options files, for | |
// example, in Packages/Python/Python.sublime-settings for python files. | |
{ | |
// Sets the colors used within the text area | |
// 主题文件的路径 | |
"color_scheme": "Packages/Color Scheme - Default/Monokai.tmTheme", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>CSS实现三角形缺口</title> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
</head> | |
<body> | |
<style type="text/css"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# wubi86.custom.yaml | |
# | |
# 在【五笔86】里使用Emoji表情 | |
# | |
patch: | |
engine/translators: | |
- punct_translator | |
- r10n_translator | |
- reverse_lookup_translator | |
recognizer/patterns/reverse_lookup: "`[a-z]*$" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
copy the following code to you current theme functions.php file: | |
*/ | |
/* | |
* Adding the column | |
*/ | |
function rd_user_id_column( $columns ) { | |
$columns['user_id'] = 'ID'; | |
return $columns; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Replace | |
<?php the_content(); ?> | |
//with | |
<?php echo mb_strimwidth(strip_tags(apply_filters('the_content', $post->post_content)), 0, 120,"......"); ?> | |
OlderNewer