• Hello all,

    Since 2004, I have a blog about wrist watches. I recently changed from the standard (but modified) Kubrick’s theme to this Mandigo theme, which I really like.

    However, since a few weeks, the blog is loading slow. The header loads without a problem, and then it takes about 8 seconds and then the rest of the website appears (at once). I rather have the website loading on the fly, so visitors see that something happens, than this.

    I tried downsizing the number of blog posts on the front page, optimizing the MySQL database tables with PHPMyAdmin, installing the WP Super Cache plug-in.. but nothing seems to help. I am at the end of thinking what it can be. I also tried analyzing the site with Yslow (FireFox add-on), but you need a fulltime study to analyze (and solve) all ‘measures of improvement’. Oh yeah, I did search on this forum of course, but didn’t find a solution (obviously).

    The strange thing is, that the page loads quite quickly on my iMac with FireFox (yes, also after clearing cache/history) but it doesn’t with Windows en Internet Explorer.

    The website is: https://www.fratellowatches.com

    Thanks in advance and looking forward to any tips!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi

    I’ve been looking at your site for about 30 minutes.

    The first thing I did is run the Firebug profiler on your page loading in Firefox after clearing cache. I put the jpg of the output online at https://s245.photobucket.com/albums/gg72/stvwlf/?action=view&current=fratello.jpg

    I noticed that it is only in IE7 (and probably IE6 which I didn’t look at) that this hesitation exists. The page loads as rapidly in IE8 as it does in IE7.

    I did notice as the profiler ran that it hesitates when loading the jQuery library – a pause in other words. Then I was looking at your homepage code in View Source and could not see the jQuery library being declared. “What is going on?” As I looked further down the home page code, I discovered that you have two body tags declared.

    In other words, the HEAD ends, the BODY starts, and then in the middle of the body, the jquery library and a few jquery scripts are being loaded. These are supposed to be loaded in the HEAD, not in the body. and then, after the jquery loads are these tags

    </head>
    <body>

    In other words, in the middle of the Body, jquery code loading belongs in the HEAD occurs, the HEAD is closed again when it wasn’t even open, and the BODY is declared again even though you already are in the BODY code. This is all bad code.

    Firefox and apparently IE8 are smart enough to work around this bad code. But IE6 and 7 often get stumped by things like this. Ten to one IE7 is hiccupping at that point trying to do something that is not at all what is intended.

    I then ran your homepage through the page validator
    https://validator.w3.org/check?uri=https://www.fratellowatches.com/
    and found 170 errors on it. Many of those errors are trivial and are not going to affect how your page assembles. But there are a number of that relate to page structure, and it is important these get cleaned up.

    You have clearly put a lot of effort into trying to solve this problem. I suggest that getting those page errors cleaned up, and resolving the jQuery and HEAD code in the middle of the BODY is the next phase of doing more of what you have already done.

    Also, your theme is loading its own version of jQuery from the theme folder. It is recommended in WP to load the version of jQuery that comes with WP – you do this by adding the line
    <?php wp_enqueue_script('jquery'); ?>
    BEFORE this line <?php wp_head(); ?>
    and load the rest of the jquery scripts AFTER <?php wp_head(); ?>

    And remove the line where the theme’s own version of the jQuery library is being loaded.

    Also, the jQuery IE6 PNG fix script looks like it is being loaded on all pages. It only needs to be loaded on IE6 and can be loaded like this to accomplish that
    <!–[if IE 6]>
    <script type=”text/javascript” src=”https://www.fratellowatches.com/wp-content/themes/mandigo/js/jquery.ifixpng.js”></script&gt;
    <![endif]–>

    Thread Starter rjbroer

    (@rjbroer)

    Hi stvwlf,

    Thanks a million for putting so much effort in your answer to my question. I will analyze your suggestions and fix the bad coding as you pointed out (making a back-up first). When reading, it all sounds very logical, so I hope this helps.

    Thanks again!

    RJ

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Blog is loading terribly slow, after showing the header first’ is closed to new replies.