Skip to content

Tag: javascript

how to put the result of JS/HTML page in table format?

I have created JS/Html page for survey but i want to show the result of survey page in table format after clicking submit button. Right now it is not coming as a table format, the answer is coming section-wise. I want one final answer which come as a table format showing result of individual section and total…

JavaScript subtract time in moment used in reactJS

I am using React Js and I would like to perform a subtract time in JavaScript with moment library. I tried my code as follows: The above code was my timecheck function, I would like to perform time3 = time1 – time2, it console log as InvalidDate May I know where is my syntax error? Answer You can simply…

Why doesn’t this code display the button after I hide it?

When I run this JavaScript code, button2 doesn’t get displayed again. I’m not sure why this is happening. I am trying to use this in a game I am creating. I searched this up on Google multiple times and couldn’t find an answer. Answer There is no auto display is CSS. As tarkh mentioned in hi…

How to get data based on username in cube js

DEFINITION I have connected my cube js backend to mongodb. I am storing documents inside my mongo db database in a following way. THIS IS HOW MY DOCUMENT LOOKS LIKE IN MONGO DB So now let us assume that I have 10 documents in my mongodb collection in which 5 documents belong to user: “abc” and 5 d…

How can I make the avatar appear in large format?

I’m new to all this, sorry for my stupidity :c is my first discord bot! when I give the command !avatar on discord, the avatar comes out very small on the right of the embed Answer Thumbnails are small. You would need to place the avatar in .setImage() then have it set to scale up to 256 in size This