求助:访问速度太慢

  • 2018-01-19
  • 373
  • 5
  • 0

待优化站点:You are special-Soul

网页响应速度感人,有什么好方法吗?


代码查找方法:grep -rn “hello,world!” *

翻译:

Discover music———————–发现音乐

Dashboard—————————-仪表板, 控制面板(dashboard)就是一种用户接口
widgets——————————小工具
Home header————————–家里头
–text 注册按钮html代码


musiks\assets\js\youtube.js line 106/108

footer.php line 19
header.php line 17:

<a style="display:none" rel="follow" href="http://megatheme.ir/" title="قالب وردپرس">قالب وردپرس</a><a style="display:none" rel="follow" href="http://megatheme.ir/wp-plugins/" title="افزونه وردپرس">افزونه وردپرس</a><a style="display:none" rel="follow" href="http://megatheme.ir/wordpress-theme/ecommerce/" title="قالب فروشگاهی وردپرس">قالب فروشگاهی وردپرس</a><a style="display:none" rel="follow" href="http://megatheme.ir/wordpress-theme/" title="قالب وردپرس">قالب وردپرس</a><a style="display:none" rel="follow" href="http://megatheme.ir/sahifa" title="قالب صحیفه">قالب صحیفه</a>

大标题英文显示不全 /musiks/assets/css/app.css:

.m-l-sm {
  margin-left: 3px;
}

2018.1.20 禁用emoji JavaScript 文件 (wp-emoji-release.min.js):

function disable_emojis() {
 remove_action( 'wp_head', 'print_emoji_detection_script', 7 );
 remove_action( 'admin_print_scripts', 'print_emoji_detection_script' );
 remove_action( 'wp_print_styles', 'print_emoji_styles' );
 remove_action( 'admin_print_styles', 'print_emoji_styles' ); 
 remove_filter( 'the_content_feed', 'wp_staticize_emoji' );
 remove_filter( 'comment_text_rss', 'wp_staticize_emoji' ); 
 remove_filter( 'wp_mail', 'wp_staticize_emoji_for_email' );
 add_filter( 'tiny_mce_plugins', 'disable_emojis_tinymce' );
}
add_action( 'init', 'disable_emojis' );
 
/**
 * remove the tinymce emojis plugin.
 */
function disable_emojis_tinymce( $plugins ) {
 if ( is_array( $plugins ) ) {
 return array_diff( $plugins, array( 'wpemoji' ) );
 } else {
 return array();
 }
}

2018.1.20 禁用 Embeds 网页崁入功能  JavaScript 文件 (wp-embed.min.js):

function my_deregister_scripts(){
wp_dequeue_script( 'wp-embed' );
}
add_action( 'wp_footer', 'my_deregister_scripts' );
2018.1.20 移除 WordPress 的 Query String From URL

function _remove_script_version( $src ){ 
$parts = explode( '?', $src ); 
return $parts[0]; 
} 
add_filter( 'script_loader_src', '_remove_script_version', 15, 1 ); 
add_filter( 'style_loader_src', '_remove_script_version', 15, 1 );

讨厌的参数,不复存在.

 

2018.1.20 禁用 XML-RPC:

XML-RPC 验证工具验证是否禁用了 XML-RPC:http://xmlrpc.eritreo.it/
add_filter( 'xmlrpc_enabled', '__return_false' );

 

2018.1.20 移除 jQuery Migrate( jquery-migrate.min.js):

function isa_remove_jquery_migrate( &$scripts) {
    if(!is_admin()) {
        $scripts->remove( 'jquery');
        $scripts->add( 'jquery', false, array( 'jquery-core' ), '1.12.4' );
    }
}
add_filter( 'wp_default_scripts', 'isa_remove_jquery_migrate' );

 

2018.1.20 移除 WordPress 版本號:

function woowp_remove_version() {
    return '';
}
    add_filter('the_generator', 'woowp_remove_version');

 

2018.1.20 移除 wlwmanifest, RSD, Shortlink 的连接:

<link rel="EditURI" type="application/rsd+xml" title="RSD" href="https://*.net/xmlrpc.php?rsd" />
<link rel="wlwmanifest" type="application/wlwmanifest+xml" href="https://*.net/wp-includes/wlwmanifest.xml" /> 
<link rel='shortlink' href='https://*.net/' />
function remheadlink() {
    remove_action( 'wp_head', 'wlwmanifest_link');
    remove_action ('wp_head', 'rsd_link');
    remove_action( 'wp_head', 'wp_shortlink_wp_head');
}
    add_action('init', 'remheadlink');

 

2018.1.20 禁用 Self Pingbacks 链接

function no_self_ping( &$links ) {
 $home = get_option( 'home' );
 foreach ( $links as $l => $link )
 if ( 0 === strpos( $link, $home ) )
 unset($links[$l]);
}
    add_action( 'pre_ping', 'no_self_ping' );

随机访问记录

63 个请求-已传输 1.43 MB / 601.91 KB-完成:7.86 秒-DOMContentLoaded: 3.37 秒-load: 5.66 秒
63 个请求-已传输 1.43 MB / 556.97 KB-完成:5.45 秒-DOMContentLoaded: 2.02 秒-load: 2.87 秒
63 个请求-已传输 1.43 MB / 557.16 KB-完成:8.37 秒-DOMContentLoaded: 1.91 秒-load: 2.00 秒
62 个请求-已传输 1.43 MB / 571.78 KB-完成:6.45 秒-DOMContentLoaded: 1.28 秒-load: 2.67 秒
63 个请求-已传输 5.30 MB / 555.78 KB-完成:7.95 秒-DOMContentLoaded: 1.77 秒-load: 2.57 秒
61 个请求-已传输 1.42 MB / 595.42 KB-完成:5.98 秒-DOMContentLoaded: 1.22 秒-load: 3.88 秒
62 个请求-已传输 5.29 MB / 595.54 KB-完成:8.61 秒-DOMContentLoaded: 1.43 秒-load: 3.68 秒
61 个请求-已传输 1.42 MB / 566.79 KB-完成:6.55 秒-DOMContentLoaded: 1.37 秒-load: 2.75 秒
 一顿优化,并没软用
2018.1.20 博客feed
/*
*指定博客feed。可以被浏览器检测到,然后被读者订阅。一般情况下,订阅用户质量不高,只会占用博客的流量,达不到seo和营销的目的,不要也罢。
*/
remove_action('wp_head', 'feed_links', 2);//文章和评论feed
remove_action('wp_head', 'feed_links_extra', 3); //分类等feed

2018.1.22 新增css

<link rel='stylesheet' id='edd-styles-css'  href='http://wpdemo.cn/musiks/wp-content/plugins/easy-digital-downloads/templates/edd.min.css?ver=2.5.17' type='text/css' media='all' />

 

The download files in wp-content/uploads/edd are not currently protected due to your site running on NGINX.

To protect them, you must add a redirect rule as explained in this guide.

If you have already added the redirect rule, you may safely dismiss this notice

Dismiss Notice

纯文本模式:

Paste is now in plain text mode. Contents will now be pasted as plain text until you toggle this option off. If you’re looking to paste rich content from Microsoft Word, try turning this option off. The editor will clean up text pasted from Word automatically.

搭建过程 银色月航大大 帮助完成

  1. 2017:  2016电信回忆录(0)

评论

  • 银色月航回复
    Google Chrome 64 Google Chrome 64 Mac OS X 10.10 Mac OS X 10.10

    哈哈,看来慢慢有头绪了

    • Waylee回复
      MIUI Browser 9 MIUI Browser 9 Android 7.1.1 Android 7.1.1

      😳 优化啊,太慢了受不了。可是我无法让他更快

  • 银色月航回复
    Google Chrome 65 Google Chrome 65 Mac OS X 10.10 Mac OS X 10.10

    速度不错啦,多更新点音乐

发表评论