First time hosting a website

Hello everyone ! For the first time I tried to host a website via a github page however I cannot seem to get my page to work : for some reason the CSS file isn’t loading, and I keep getting the error “GET net::ERR_ABORTED”

It is the first time i’m acutally hosting a website, so i’m not sure what i’m doing wrong.

The main file containes the index.html and 3 files containing the css sheet, the javascript file and the images for the website, named respectively “css”,“js”,“img”, and here’s my index.html file :

    <title>TIC TAC TOE</title>
    <link href="/css/style.css" rel="stylesheet" type="text/css" />
    <link href="" rel="stylesheet">
    <div class="main">
      <div class="wrapper">
        <div class="outer"> 
       	  <div class= "winBox">
		    <p><span class="winner"></span>   Wins !!</p>
	      <div class = "character">
	      <div class = "ptext" style="width : 100%;">
		  <p>Choose your Character ! </p>
        <table id="tb">
    <button class="reset">reset</button>

<script src=""></script>  
<script src = '/JS/tictactoeScript.js'></script>  


I really don’t know what do to :confused: Any help would be appreciated ! Thanks a lot !

The path is case sensitive! I hope that helps! :smile:

1 Like

I feel so stupid right now --"

Thanks a bunch ! It’s weird the case is sensitive when hosted but not when launched from the desktop :o You saved me hours of looking around <3

When you open your file from the desktop, you aren’t really visiting a URL, so it’s not case sensitive. Opening a file on your computer in your browser loads all the files like it would if you typed it into your file system. Your computer’s file system probably isn’t case sensitive, so for example if you open C:\PROGRAM Files that will be the exact same thing as C:\Program Files.

URL’s are case sensitive. If you were running a web server locally, then you would have to have exact URL matches. http://localhost/css/style.css would not work even though you are still on your own computer. But again, when you are just viewing a file in the browser, you aren’t really using a URL so I believe it follows file system rules.

If a site is hosted on a Linux server, filenames/paths will be case sensitive.

If hosted on a Windows server, it’s NOT case sensitive.

1 Like