Trying to fix JS on Randomizer
This commit is contained in:
parent
45ceecee0a
commit
fe752192ff
2 changed files with 2 additions and 2 deletions
|
@ -6,7 +6,7 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
onMount(() => {
|
onMount(() => {
|
||||||
document.getElementById('banner').src = document.getElementById('banner').src.replace("pic0", `pic${rand(1,10)}`);
|
document.getElementById('banner').src = document.getElementById('banner').src.replace("pic0.png", `pic${rand(1,10)}.png`);
|
||||||
console.log(document.getElementById('banner').src);
|
console.log(document.getElementById('banner').src);
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- svelte-ignore a11y-img-redundant-alt -->
|
<!-- svelte-ignore a11y-img-redundant-alt -->
|
||||||
<a href="/gallery" class="banner" data-tooltip="See more..."><img src="assets/images/gallery/pic0.png" id="banner" alt="Random picture from the gallery."></a>
|
<a href="/gallery" class="banner" data-tooltip="See more..."><img src="http://localhost:3001/pic0.png" id="banner" alt="Random picture from the gallery."></a>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
a.banner {
|
a.banner {
|
||||||
|
|
Loading…
Reference in a new issue