0
What can make document.write undefined?
I was writing a very simple code but this notification keeps coming that document is undefined :/ (The document of document.write)
10 Réponses
0
Try console.log()
0
Now it says console is undefined.
0
Can i have a look at your code?
0
It's like
var name='Bob';
console.log(name);
Or
document.write(name)
0
var name = "Bob";
document.write(name);
0
The code i send should work
0
var name = "Bob";
document.write(name);
Does this work for you in code playground?Because it doesn't for me.
0
Yes it works. Are you sure you are using js and not java?
0
It works for me too but not in computer. Maybe I should use another text editor.
0
On computer you can use Visual Studio code. But when you write in js you have to include it in Html.