Home Entrance Everyone Wiki Search Login Register

Welcome, Guest. Please login or register. - Thinking of joining the forum??
April 28, 2024 - @555.19 (what is this?)
Forum activity rating: Four Star Posts: 66/1k.beats Unread Topics | Unread Replies | Own Posts | Own Topics | Random Topic | Recent Posts
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 326 times)
KittyTheKat
Casual Poster ⚓︎
*


Any/All and Agender

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 ⚓︎
****


is it any wonder that my mind's on fire?

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


rock operatic science fantasy and more...
(...all opinions mine unless attributed, and free to a good home...)
KittyTheKat
Casual Poster ⚓︎
*


Any/All and Agender

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 ⚓︎
****


is it any wonder that my mind's on fire?

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


rock operatic science fantasy and more...
(...all opinions mine unless attributed, and free to a good home...)
Pages: [1] Print 
« previous next »
 

Vaguely similar topics! (3)

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

Started by MelooonBoard ⁇ ∙ Tutorials

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

Started by MelooonBoard ✎ ∙ Art Crafting

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

Started by sigBoard ♖ ∙ Video Games

Replies: 5
Views: 526
Last post March 09, 2023 @990.24
by Guest

Melonking.Net © Always and ever was! SMF 2.0.19 | SMF © 2021, Simple Machines | Terms and Policies Forum Guide | Rules | RSS | WAP2


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