Artifacts Gallery Guilds Search Wiki Login Register

Welcome, Guest. Please login or register. - Thinking of joining?
a Summer night - @961.71 (what is this?)
Activity rating: Four Stars Posts & Arts: 57/1k.beats Random | Recent Posts | Guild Recents
News: inconvenience is counterculture :eyes: Guild Events: HOMESTUCK ART-APALOOZA

+  MelonLand Forum
|-+  Life & The Web
| |-+  ✁ ∙ Web Crafting
| | |-+  ☔︎ ∙ I need Help!
| | | |-+  Problem stylising on neocities when html files are sorted into folders


« previous next »
Pages: [1] Print Embed
Author Topic: Problem stylising on neocities when html files are sorted into folders  (Read 27 times)
taraellenrose
Newbie ⚓︎
*
View Profile WWW


⛺︎ My Room

Artifacts:
Joined 2026!
« on: a Summer night » Embed

Hihihi!!! I'm brand new to coding and I've been using neocities to host my site. I'm programming a blog site and I created a folder to put my blogs in to keep them organised but unfortunately I'm having issues with stylising them as a result, particularly adding the background image to my code/page. When everything was out on the dashboard it worked just fine, its just messed up in the folder, but I don't want to leave everything out on the dash bc its soooo messy. I've tried to create another file for the image in the folder aswell but that doesn't make any odds. Tbh i just copied the code from a youtube video so I'm not sure what it actually does. I'm brand new to html and I don't know any css. I'll copy the code below but it works fine with putting a background pic in index.html i think it is just a problem with the folders??? lmk if you've had this issue and any advice and help would be much appreciated

<style>
  body{
    background-image: url(blogs/wallpaper.jpeg);
  }
</style>

also!!

<style>
  body{
    background-image: <img src="blogs/wallpaper.jpeg"/>;
</style>

doesn't work either but as I said the first code works fine outside of the folder. so idk :ohdear:
Logged
sweetwana
Casual Poster ⚓︎
*
View Profile WWWArt


Virtual Moss
⛺︎ My Room

Guild Memberships:
Artifacts:
Princess KuromiSurfs Up!Joined 2026!
« Reply #1 on: a Summer night » Embed

Hi hiiii

I am also very much a beginner at this, but I took a look at my code in my stylesheet and noticed that I have a forward slash before the first folder name. I have something in the back of my head that makes me think it didn’t work before I added it?

But I might be wrong!

So mine is like…

background-image: url('/images/grassybackground.jpg');

(I am so sorry if this is a red herring, and also I love the castle in your picture!)
Logged

https://sproutknip.neocities.org/images/sootsprites.gifhttps://sproutknip.neocities.org/images/sproutknipbutton.gifhttps://sproutknip.neocities.org/images/sootsprites.gif

Artifact Swap: sunsetMoonlight MopedsmoldiamundBeetle BoxLike MailMetabee3 coinsSanriotoroKuromi
gh0ulixh
Newbie ⚓︎
*
View Profile WWW


⛺︎ My Room

Guild Memberships:
Artifacts:
Joined 2026!
« Reply #2 on: a Summer night » Embed

I am also very much a beginner at this, but I took a look at my code in my stylesheet and noticed that I have a forward slash before the first folder name. I have something in the back of my head that makes me think it didn’t work before I added it?

background-image: url('/images/grassybackground.jpg');

(I am so sorry if this is a red herring, and also I love the castle in your picture!)

i'm new to coding myself, but in my experience, like sweetwana said, the inclusion of the starting forward slash (/) is how to get the code to recognize the path to the image you're referencing properly   :4u:
Logged
taraellenrose
Newbie ⚓︎
*
View Profile WWW


⛺︎ My Room

Artifacts:
Joined 2026!
« Reply #3 on: a Summer night » Embed

thanks for the advice!! I'll give it a shot and let you know if it works :)) also the castle is in my hometown, i'm very lucky to live in such a cool place :D
Logged
taraellenrose
Newbie ⚓︎
*
View Profile WWW


⛺︎ My Room

Artifacts:
Joined 2026!
« Reply #4 on: a Summer night » Embed

eeeeee thank you both so much it worked like a dream!!! :DDD
Logged
sweetwana
Casual Poster ⚓︎
*
View Profile WWWArt


Virtual Moss
⛺︎ My Room

Guild Memberships:
Artifacts:
Princess KuromiSurfs Up!Joined 2026!
« Reply #5 on: a Summer night » Embed

Ooh, fellow castle-hometown-haver!

Glad I was able to help! Wahoo! I enjoyed reading your blog posts. I don’t know you, but it felt like hearing from a friend  :4u:
Logged

https://sproutknip.neocities.org/images/sootsprites.gifhttps://sproutknip.neocities.org/images/sproutknipbutton.gifhttps://sproutknip.neocities.org/images/sootsprites.gif

Artifact Swap: sunsetMoonlight MopedsmoldiamundBeetle BoxLike MailMetabee3 coinsSanriotoroKuromi
Pages: [1] Print Embed 
« previous next »
 

Melonking.Net © Always and ever was! SMF 2.0.19 | SMF © 2021 | Privacy Notice | Send Feedback | Supporters ♥ Forum Guide | Rules | RSS | WAP | Mobile


MelonLand Badges and Other Melon Sites!

MelonLand Project! Visit the MelonLand Forum! Support the Forum
Visit Melonking.Net! Visit the Gif Gallery! Pixel Sea TamaNOTchi
MelonLand @000

Minecraft: Online
Join: craft.melonking.net