Skip to content

Tag: javascript

If the input I put blank, then it will count 0

I am trying to put some amount, then it will show the calculation if all input will given any number, but I want, when I do not put anything in any one of that input, then the input will count “0” automatically.. Answer You can use the OR operator to replace NaN with 0 if parseFloat returns NaN. Y…

Can I get data from localstorage using php

Can I get data from localstorage using php if yes then tell me how in localstorage data set like this Answer No, you can’t. PHP runs on your server, the localStorage is only available in the browser of the client. The only way is to read the localStorage via JavaScript, and send the result to your serve…

Only hide the window when closing it [Electron]

I try to hide my main window so that I hasn’t to load again later. I got the following code: So that’s not working for me, when I close the window I get this error message: Can somebody help me? Line 37 is the line with win.hide() Thank you! Answer Use the close event instead of the closed event. …