r/neocities • • 3d ago

Question JavaScript help

Post image

can someone help me with this page??? no matter what I do I can’t seem to get my code to work? (a vid would be most helpful but literally anything plsssss 😭 ive been doing this one step for an hour)

8 Upvotes

3 comments sorted by

3

u/FrostingEffective699 yuri-uran.nekoweb.org 2d ago
var fact = factz[Math.floor(Math.random() * factz.length)]
			document.getElementById('fact').textContent = fact

you've still got the 'written by js!' string, it might be confusing the script!

2

u/xxcrucialxx 21h ago

If I'm not mistaken, try this written by js' ;

1

u/xxcrucialxx 21h ago

Give that a try