![]() |
Create Popup Message Using Js |
Summery
Basically Today in this post we go to learn about how we create popup message or popup window by using java script. We not only use java script but also mix some amount of HTML and CSS. But to create a popup window we only use Java script.
About Us
My Name is Sheikh Gulzaar. I studied in BCA (bachelor in computer application). Create this blog to provide my personal tips and tricks about various type of programming language. Any visitor can join us free and learn programming language with us. Any one can also clear their doubts by sending message in live chart option which is in under right corner. So keep supporting & keep learning.
Main Topic
Today in this article we learn how we create popup window or popup message by using java script. We also complete this project by using basic HTML and CSS codes. Here we also provide these information in our YouTube video so make sure you should see this.
Watch our video where we create this project live. And please subscribe our YouTube channel. We also make this type of intresting video in future.
Source Codes
So here is some basic source code which we create in this video and run. Generally we provide two type of source code- 1.Popup window and 2.Popup message in button format.
1.Popup Window
//* copy these codes and paste *//
<script>
window.alert("This is a popup window");
</script>
2.Popup Message
*// Add html first //*
<button onclick="mainfunction()">Try me</button>
*// then add Js //*
<script>
function mainfunction() {
alert("This is popup message in button format");
}
</script>
If you have any doubts then you can easily chart with us live by clicking green logo which is under-right side of the screen corner. We try to solve your doubts as soon as possible.