Skip to content

Tag: html

javascript InnerHTML adding cards only one time

I’m trying to add a bootstrap card inside a div called [itemscontainer] using javascript by document.getElementById(“itemscontainer”).innerHTML so i want the cards to be inserted inside the itemscontainer only one time like this :- but the problem is the items cards keeps reapet them salves …

Javascript template called inside html

I have the below code to show a timeline modal. It’s called on click using: How can I show it on my page as part of the page, not opening as a modal? I want to be always visible on that page instead of clicking on a menu to see it Any help will be much appreciated as pretty much

Why it doesn’t show the bluish in blue majority?

So I was creating an app in which I would click on a button and it would generate a color with its details in JavaScript (vanilla), details are given in a <h1> tag. One of the details is telling if the thing is red, green or blue majority. The website functions properly, but there’s a bug. When th…

Js .classList.add() is not working properly

I’m in a procces of creaing simple movie site. cruntly working there home page. in the home page there is a carosol. in CSS I hidden the visibility of all slide. what I’m going do is in JS creat a array for all silds and switch between silds when I clicked the arrow icon. as a first stem I want

After clicking button, alert is not showing up

I am doing a project on paper-rock-scissor that has UI. So, I have four buttons, Start game, rock, paper and scissor. I want if I click on the Start game button, an alert (“Please choose rock, paper, or scissor”) will pop-up. Right now if I click on the Start game. There’s nothing happening.…