Jekyll path generation


#1

i developed a website using jekyll but it’s making path to css file or picture absolute like adding localhost:400/css/main.css which can’t be accessed without localhost.Do anyone have any idea how can i fix it


#2

it is only doing that when you do jekyll serve - do jekyll build and it should give you the correct url for production.


#3

by using jekyll build it’s starting path with a /css/main.css, which also is not valid path. is there anything i can do to solve it


#4

how are you writing the links? config file contents? a repo would be helpful.


#5

{{siteurl}}/{{baseurl}}/form/index.html


#6

and what are those set to in the config?

well, I think you need site.baseurl not just baseurl same for siteurl you have to tell it that it is site data which is from the config file…


#7

thanks for your time i had understood the problem.:smiley::smiley:


#8

I had uploaded a webite on github on this link https://irtazahussain1.github.io/NLPTDemo/ . there my site is not reading path for styling sheet and other folders path


#9

you have a space in the link to jquery which is breaking it.