Page gets stuck on the first load. After update (refresh) works normal. If clear cache, back to lock

Asked

Viewed 230 times

-1

this problem is bothering me for a few days already.. I researched and made several checks and changes and can not find the problem.

The page gets stuck in the shipment for some reason.

  • If you go to the 'inspecter' you will see that the page is fully loaded in html, but does not render and is 'WHITE', although the links appear when you hover over;

  • after the refresh, the page loads and works normally.. and keeps working until the cache is cleared, then it hangs again;

  • Strange is that there is no error in the console or anything;

  • this problem is in several browsers and in other computers in different places;

see for yourselves:

ps: unless q change the useragent can not test accessing with mobile, because Voce will be redirected to the mobile site, where there is no more this error

http://romapy.com/index.php

thank you

1 answer

1

Your page only loaded after I clicked on "stop loading" from the browser and then on "Refresh"

It was really a question of organizing the scripts relative to others and the jquery library, with a php file in the middle.

I used a php file to include several scripts, and for some reason I did not identify it properly, some of these scripts, including a jquery library was loaded into the cache the first time q was loaded, and the site loading crashed when downloading this library. Therefore, the second time that the site was accessed worked normally and even uploaded faster, because the necessary files were already in the cache. When clearing cache gave the same problem.

The problem was difficult to identify because there was no error. The CLONE of @Leo Caraciiolo helped a lot, because the clone was no problem and I could see that it was something that happened when I downloaded these scripts included through the php file, because in the clone, the scripts were already included in the code.

Well, so I took all scripts out of the php file, and reorganized my scripts by following this document:

https://developers.google.com/speed/docs/insights/BlockingJS

Conclusion: 1. I have used several times php files to generate dynamic scripts, but at least q this technique is indispensable, it is not a good practice to use it. Besides slowing down loading can give page blocking problems.

  1. Organization of scripts is important and directly linked with the performance of the page. Attention to this.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.