• Dear,
    I got a big problem in loading css & js files in Head tag in index.php. The problem happens with Chrome, but Firefox is okie.
    When I open my website with Chrome, there is about 10px padding from top. When I open Chrome’s Inspect elements, I see an abnormal. There’s nothing loaded in <head> tag, <title> and all other css, js & meta tag loaded in <body> tag. When I view the code, everything is right, and normal.
    This is the code from Inspect Element:
    ========================================================
    <!DOCTYPE html>
    <html>
    <head></head>
    <body <body cz-shortcut-listen=”true”>
    ” “
    <title>My website | Tâm Vũ Nguyệt Lau</title>
    <meta charset=”UTF-8″>
    <meta name=”viewport” content=”width=device-width, initial-scale=1.0″>
    <link rel=”shortcut icon” href=”img/favicon.ico”>
    <link rel=”stylesheet” id=”main-css” href=”http://localhost/tamvu/wp-content/themes/job/style.css&#8221; type=”text/css” media=”all”>
    <link rel=”stylesheet” id=”main-css” href=”http://localhost/tamvu/wp-content/themes/job/css/job.css&#8221; type=”text/css” media=”all”>

    ===========================================================
    Please help me to find out the solution to this. This makes my website not appear in IE.
    You can check it at: http://onthitienganh.net
    I manual adapt this theme from smashingmagazine.com

Viewing 4 replies - 1 through 4 (of 4 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Which theme are you having issues with?

    I manual adapt this theme

    Does that mean you created it from scratch?

    Thread Starter donhathuy

    (@donhathuy)

    I just add some php function to HTML code. However, it appears right with Firefox. The problem is only on Chrome, and on the homepage. The single post which I use almost the same template appearing well.

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    If you’ve having issues with browser compatibility try validating your HTML http://validator.w3.org/

    If there are no HTML issues then you may need the support of a CSS forum like http://csscreator.com

    Thread Starter donhathuy

    (@donhathuy)

    oh, I have found out the reason. It’s caused by the function.php file. I don’t know what really wrong with this, because even it’s a blank file, the problem still occurs. Only remove the function.php, everything load correctly. But, I can’t control sidebar, menus, etc.
    Any ideas about this?

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Can't load css & js in the right way in index.php’ is closed to new replies.