#3255
AvatarMarwit
Supported

Hello,

I started optimizing * .php files in my own way…

File before modification: wp-blog-header.php


<?php
/**
 * Loads the WordPress environment and template.
 *
 * @package WordPress
 */

if ( ! isset( $wp_did_header ) ) {

	$wp_did_header = true;

	// Load the WordPress library.
	require_once __DIR__ . '/wp-load.php';

	// Set up the WordPress query.
	wp();

	// Load the theme template.
	require_once ABSPATH . WPINC . '/template-loader.php';

}


After modification:

<?php
if ( ! isset( $wp_did_header ) ) {
$wp_did_header = true;
require_once __DIR__ . '/wp-load.php';
wp();
require_once ABSPATH . WPINC . '/template-loader.php';
}

Of course i will do it the old fashioned way….

But this is my way and it works great, not much has changed on the speed test counters, but by switching sides the speed is phenomenal and responds in a second, not lagging 15 sec

Ps: I know there is some windows program for this that cleaned files from breaks and green comments, but I can’t find it. It may seem dumb, but even if the cache system does not fully compress, the files will always be much lighter…

Even if your theme is a bit lagging, the theme is still great..

Greetings to all your team !
Marc