My intellij can't recognise path to images and other files but when i use ctlr+left mb it finds file or image without problem. Im working with other ppl and we share it on github and only i have this problem. When i run application web pages are completely fine but when im trying to just view html file it doesnt recognise css and images. I tried creating project again, clearing cache and reinstalling ide. Photo shows files in project
how files are structured
EDIT:
Im trying to view html file clicking this and that is the result. Css and images are missing even though path seems to be correct. Problem occures on my computer. Program works on my teammate pc
Related
Good Morning Everyone, So basically I have Brackets And File Zila, And I'm currently working on my final project however whenever I do the live preview in Brackets to check to make sure everything shows up and works correctly the url shows up as "http://127.0.0.1:61913/index.html" and my .html are all uploaded to file zilla and I'm connected to the server so I don't what's wrong I have tried to unconnect to the server and reconnect, I made sure that all the .html files in file zila match the same ones I have in Brackets and my wwwroot folder, and that I have the same images and favicon image as I do in Brackets as well. So if someone could please help me with this that would be great!
Live preview and your uploading your files to your own unique website are 2 very different things.
The live preview address is just your own IP (be careful showing this publicly, as it can be abused)
Live preview: preview of whatever file you are working on, only visible by you
Uploaded files through filezilla to your own website: public on your website, can be accessed by anyone
Keep in mind whatever changes you make in brackets that are shown in live preview are not visible on your website until you upload them through filezilla.
So I began studying code this month and I'm doing an online Web Development Bootcamp. My first assignment was to create a publish a simple HTML site on GitHub. I just published my site but when I go and check it out, the image is broken, which wasn't happening on the Offline version.
So this noob here needs help trying to figure out what I did wrong.
sakurach4n's first HTML project
This commonly happens when migrating from a local site to a live site.
The "src" for the image needs to be published/hosted somewhere on the web so it has a direct URL to the image, like this image of a cat: https://ichef.bbci.co.uk/news/1024/cpsprodpb/151AB/production/_111434468_gettyimages-1143489763.jpg
It works locally because that file is present on your local machine in a folder somewhere. Because the file path is relative it now searches for the image like this: https://sakurach4n.github.io/images/mafalda.png (which does not exist)
Weird problem I'm running into... This anchor tag
<a target='_blank' href='jresume.pdf'>Resume</a>
is working fine locally. Opens a new page and loads my pdf file.
But for some reason when I deploy my site to surge.sh the link no longer works and gives me this error "No webpage was found for the web address: http://sitename.surge.sh/jresume.pdf"
if anyone could help that'd be great. Thanks
The first step I would take is to make sure the file is in the right place on your web server (have you actually uploaded the file to your web server?). I guess that'd be in the same folder as your index.html or the same folder as whatever html file is linking to it.
If that's not the problem I'd try changing href='jresume.pdf' to href='./jresume.pdf' and seeing if it makes a difference.
I have been getting to grips with html for the past two days. I understand how internal links work perfectly fine. The problem is getting the path to correctly redirect to the main page. The reason I ask, is I have looked all over and it's implicitly stated that "../index.html" (specifically the '../') will look to the previous folder.
It keeps telling me file not found. I even tried using the complete root path and it still won't work. Maybe this is slightly different on Mac? As I also can't get my .jpg files to show properly. My image files are located in the same folder as index.html.
Mac OS X 10.9.5
EDIT: Something strange, look at what the file path is showing in the browser.
file path
I have a website hosted by Github and I am having issues with displaying pictures. I recently tried to upload new pictures but despite the path being right, the page fails to load the images and gives a 404 error in the source as it tries to find the path. Here is the repo of my site: https://github.com/jeanturban/jeanturban.github.io
I think it might have something to do with Picasa as when I download a picture from the internet and update the path accordingly it works fine. But when I try to use pictures from my computer, or if I try to export from Picasa to my "img" folder, then it breaks. Perhaps Picasa is making a hidden folder upon exporting the pictures that is not being uploaded? Anyone have any insight on this? Or a workaround?
It looks like your images are not loading due to the wrong file extension. You are trying to load "http://jeanturban.com/img/Current/light1.jpg" when it should be "http://jeanturban.com/img/Current/light1.JPG" -- notice the capital JPG at the end.
The issue in my case was my images where in a .attachments folder (coming from Azure DevOps) and I guess GitHub pages skipped hidden folders.
I had same issue but image case was not problem.
What fixed it was shortening image file name from 26 characters with three underscores to 16 characters and one underscore.
I had to change the path for where my media files were stored for my case:
before my file setup was:
-myusername.github.io
-->index.html
-->index.css
->media
-->myImage.jpg
after I changed it to the setup below, it worked:
I had to change it to this:
->myusername.github.io
-->index.html
-->index.css
-->media
--->myImage.jpg