+ 3

How are individual code docs attached/referenced?

Having trouble getting a clear answer through Google. So lets say I want to make a web page that uses html, css, and JavaScript but I don't want everything in the html. I want an individual css doc and JS doc. I know href can be used to reference files but does it simply need to be in a folder then you just copy that file path? I.e. <a href>C:/user/me/code/mycode.js</a> (Also, pretty sure that href line is written incorrectly but you get what I mean)

14th Jun 2018, 3:31 PM
Soup Master
Soup Master - avatar
1 ответ
+ 1
Hi Shane! It looks like you might be wanting to implement the file setup on your home computer (instead of hosting it on a server for public availability, which is more complicated). I haven't tested this on a Windows PC, but it definitely works in Linux. Please find sample code and file name indicators in the link below. https://code.sololearn.com/Wey3T90cWCV0/#html You will want to view all three tabs (HTML, CSS, and JS) in the demo. Note: To keep things easy, I've assumed that all three files will be in the same folder so that you don't have to add file paths. I hope this helps! If you have any additional questions, please don't hesitate to reach out!
16th Jun 2018, 11:06 AM
Janning - avatar