Home Events! Entrance Everyone Wiki Search Login Register

Welcome, Guest. Please login or register. - Thinking of joining the forum??
November 22, 2024 - @283.92 (what is this?)
Forum activity rating: Three Stars Posts: 38/1k.beats Unread Topics | Unread Replies | My Stuff | Random Topic | Recent Posts    Start New Topic
News: :4u: ~~~~~~~~~~~  :4u:

+  MelonLand Forum
|-+  World Wild Web
| |-+  ✁ ∙ Web Crafting
| | |-+  ☔︎ ∙ I need Help!
| | | |-+  HELP: Prevent images from flickering when they load in?


« previous next »
Pages: [1] Print
Author Topic: HELP: Prevent images from flickering when they load in?  (Read 652 times)
KittyTheKat
Casual Poster ⚓︎
*


Any/All and Agender

⛺︎ My Room
iMood: KittyTheKat

View Profile WWW

First 1000 Members!Joined 2023!
« on: July 22, 2023 @860.87 »

Recently there have been a few situations with my site where images 'flicker' out when the site loads them in. Right now it's visible with the background of my main pages, which is surprising to me given that it's a small image that's just tiled. Any ideas on how to fix this? Preloading it as a hidden image doesn't seem to help.
Edit: It's most noticeable when switching between my main page and my badges page which makes me think it may have to do with how many images it has to pull.
« Last Edit: July 22, 2023 @863.63 by KittyTheKat » Logged

"Hell is other people. But that’s only that side of the coin. The other side, which no one seems to mention, is also “Heaven is each other.” … Hell is separateness, uncommunicability, self-centeredness, lust for power, for riches, for fame. Heaven, on the other hand, is very simple—and very hard: caring about your fellow beings." -Jean-Paul Sartre
starbreaker
Sr. Member ⚓︎
****


What good is Heaven if we dare not storm it?

⛺︎ My Room
SpaceHey: Friend Me!

View Profile WWW

First 1000 Members!G4 Club Member!Joined 2023!
« Reply #1 on: July 22, 2023 @880.20 »

If you can, it might be helpful to specify the width and height in pixels of your images when you create your <img> tags. For example, this is what you've got so far:

Code
<img src="https://kittythekat.neocities.org/images/moomin.jpg">

If you did this instead:

Code
<img src="https://kittythekat.neocities.org/images/moomin.jpg" width="540" height="447" alt="a moomin comic panel" loading="lazy">

The browser would know to allocate a space 540 pixels wide and 447 pixels high for this image before it's finished downloading. In addition, specifying "alt" text lets the browser display an image description if the image isn't available for whatever reason, and also makes your site more accessible to people who need to use screen readers. Finally, setting the image to lazy load means that the browser won't wait for the image to load, but only load the image when the user scrolls down far enough for it to be needed. This can help performance if your page has a lot of images.

Hope this helps.
Logged

KittyTheKat
Casual Poster ⚓︎
*


Any/All and Agender

⛺︎ My Room
iMood: KittyTheKat

View Profile WWW

First 1000 Members!Joined 2023!
« Reply #2 on: July 22, 2023 @905.32 »

@starbreaker All very helpful notes, thank you! :smile:
Logged

"Hell is other people. But that’s only that side of the coin. The other side, which no one seems to mention, is also “Heaven is each other.” … Hell is separateness, uncommunicability, self-centeredness, lust for power, for riches, for fame. Heaven, on the other hand, is very simple—and very hard: caring about your fellow beings." -Jean-Paul Sartre
starbreaker
Sr. Member ⚓︎
****


What good is Heaven if we dare not storm it?

⛺︎ My Room
SpaceHey: Friend Me!

View Profile WWW

First 1000 Members!G4 Club Member!Joined 2023!
« Reply #3 on: July 23, 2023 @959.33 »

You
@starbreaker All very helpful notes, thank you! :smile:

You're welcome. Glad I could help.
Logged

Pages: [1] Print 
« previous next »
 

Vaguely similar topics! (3)

GUIDE: Mac - Quick compressing images for the web with Automator

Started by MelooonBoard ✁ ∙ Web Crafting

Replies: 0
Views: 1604
Last post June 05, 2022 @634.22
by Melooon
Nvidia Instant NeRF (Images to 3D scene)

Started by MelooonBoard ✎ ∙ Art Crafting

Replies: 0
Views: 1074
Last post November 04, 2022 @838.52
by Melooon
FromSoftware / Soulsborne Games

Started by sigBoard ♖ ∙ Video Games

Replies: 5
Views: 956
Last post March 09, 2023 @990.24
by Memory

Melonking.Net © Always and ever was! SMF 2.0.19 | SMF © 2021, Simple Machines | Terms and Policies 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