Although the website files are completely the same in both hosting accounts, the site appearance is very different, and i can see that the second link give me this error:
its strange, as i can see all these files in the File Manager.
Also, i tried to delete and reupload VisitorManagement.js and it still gets a 404.
And i have already tried to reupload everything in the past.
The files are indeed the same, but the URLs you are using are different.
On the free subdomain, you are accessing the index.html file in the speech_2_dymo folder. And in the HTML code, the URLs are all relative to the current folder, so the URL to a file looks like https://farmeasy.epizy.com/speech_2_dymo/jquery.hotkeys.js?_=1657551125747.
On the custom domain, you are accessing the page as https://www.speaklabel.cc/. So the final URLs look like https://www.speaklabel.cc/assets/vendor/popper/popper.min.js.
However, like with the free subdomain, all the website files are located in the speech_2_dymo folder, not the main htdocs folder, which is why the files cannot be found.
There are roughly two ways to fix this:
Simply move all the files from the speech_2_dymo folder to the main htdocs folder.
Setup .htaccess rules to remap all (non-existent) URLs in the main folder to the speech_2_dymo folder.
First of all thank you for the quick and detailed response.
Solution 1 worked just fine.
Although, i cannot still understand why i had this folders conflict, as i always use relative links and not “hardcoded” full links e.g. I dont use https://farmeasy.epizy.com/speech_2_dymo/jquery.hotkeys.js?_=1657551125747 but /jquery.hotkeys.js or something like that.
How you format the links makes a huge difference on how the browser interprets them. So it’s very useful to understand the different ways to write URLs and how they are handled by browsers.
It’s not really a “conflict”. The file you’re trying to use is located at https://www.speaklabel.cc/speech_2_dymo/jquery.hotkeys.js. So on the HTML page, you need to place a URL that ultimately goes to that specific URL.
If you then use the URL which is just jquery.hotkeys.js, the browser will understand this URL as being relative to the current directory. So on https://farmeasy.epizy.com/speech_2_dymo/index.html, this becomes https://farmeasy.epizy.com/speech_2_dymo/jquery.hotkeys.js, which is good. But on https://www.speaklabel.cc/index.html, this becomes https://www.speaklabel.cc/jquery.hotkeys.js. And that’s a different URL, which is why it doesn’t work.
To serve a file on a website, you need to tell the server exactly where to find it. You can’t just give it a file name and it will just kinda search your account for a file somewhere in some folder that might be the one you’re looking for. That search operation is theoretically possible, but would be extremely slow at scale, but it’s generally quite easy to fix through code.