I have a PHP page. In the header I have added a style sheet (style.css) like this:
<head>
<meta charset="UTF-8">
<meta http-equiv="Content-type" content="text/html; charset=UTF-8">
<title><?php echo $user['first'] . ' ' . $user['last'] ?></title>
<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css" />
<link href="css/style.css" type="text/css" rel="stylesheet">
</head>
I have the file in the correct location. I am running the code locally using the command php -S localhost:3000
But I keep getting this error
The stylesheet http://localhost:3000/index.php/css/style.css was not loaded because its MIME type, “text/html”, is not “text/css”. index.php
Also, I uploaded this code to my server and it is working fine. I get this issue only while running on my system. I tried to disable cache and open the URL in incognito mode, nothing seems to be working. There is no error in the CSS file, I have validated using jigsaw.w3.org.