"Alert" does not work. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

"Alert" does not work.

Hi, I started to study js and faced with such a problem, the “notification” (alert) does not work, there are no notifications on the screen, what could it be connected with? The js file is connected, alert does not work, even if I write in html, I use the additional jQuery library, everything is connected. I apologize for the "crooked" text, I do not know English well. if I write in html, I use the optional jQuery library, everything is connected. I apologize for the "crooked" text, I do not know English well.

21st Jun 2020, 10:01 AM
Мяу Мур
20 Answers
+ 13
in js, write this alert("hello");
21st Jun 2020, 10:06 AM
ÃKR
ÃKR - avatar
+ 2
In html file <body><script type="text/javascript"> alert("123..."); </script></body>
21st Jun 2020, 10:11 AM
Мяу Мур
+ 2
<html> <head>Alert</head> <body> <script> alert("I am from alert function"); </script> </body> </html>
23rd Jun 2020, 7:11 AM
Sounak Das
Sounak Das - avatar
+ 1
It doesn’t work, I don’t know why
21st Jun 2020, 10:07 AM
Мяу Мур
+ 1
It doesn’t work, I don’t know why
21st Jun 2020, 10:08 AM
Мяу Мур
+ 1
Could this be due to the fact that I am using the jQuery library or with the features of the editor?
21st Jun 2020, 10:14 AM
Мяу Мур
+ 1
🤔 it's working all right for me . Cheque it again
21st Jun 2020, 10:37 AM
Ayush Kumar
Ayush Kumar - avatar
+ 1
Could this be related to my editor?
21st Jun 2020, 2:35 PM
Мяу Мур
+ 1
Alert is work in case you write all code without speaing mistack lick me
22nd Jun 2020, 10:05 AM
Nimesh A Kadecha
Nimesh A Kadecha - avatar
+ 1
You can write like alert("your text");
22nd Jun 2020, 6:58 PM
Saitheja Komalla
Saitheja Komalla - avatar
0
Try that with html
22nd Jun 2020, 10:10 AM
Nimesh A Kadecha
Nimesh A Kadecha - avatar
0
Which ones do you use?
22nd Jun 2020, 10:40 AM
Мяу Мур
0
Chack my profile i creat a code in web lick and type as it is you get the reasult
22nd Jun 2020, 10:46 AM
Nimesh A Kadecha
Nimesh A Kadecha - avatar
0
try this: go to google chrome and press F12 this will take you to the console now type this on the console; alert('it works!'); then hit enter this should bring the alert box. to use it in the program put that code in your javascript but just make sure the script is liked properly to the html page and is at the bottom of the body tags. <script type='text/javascript' src='index.js'></script>
22nd Jun 2020, 7:39 PM
moses
moses - avatar
0
Try use Visual Studio Code it's perfect and free and straight forward and trust worthy you can even use the live server extension which enables hot reloading
22nd Jun 2020, 7:41 PM
moses
moses - avatar
0
Mry Myp jquery is good with alert
23rd Jun 2020, 2:35 AM
Sali65
Sali65 - avatar
0
Try restarting the application. I do think it will have to work
23rd Jun 2020, 4:33 AM
Mulochi Ronny Luther
Mulochi Ronny Luther - avatar
0
To get alert of hi copy this all code html to /html <html> <head>alert of hi</head> <body> <script> alert { ("Hi") } </script> </body> </html>
23rd Jun 2020, 6:33 AM
Nimesh A Kadecha
Nimesh A Kadecha - avatar
- 1
Please tell me the normal code editor for smartphones that will read js, I launched the project on the computer, everything works, this is a defect of the editor
22nd Jun 2020, 10:10 AM
Мяу Мур