Skip to content
Related Articles

Related Articles

HTML | Window createPopup() Method

View Discussion
Improve Article
Save Article
Like Article
  • Last Updated : 11 Oct, 2019

The createPopup() method in html window is used to create a pop-up window.




      DOM createPopup() Method
        h1 {
            color: green;
    <script type="text/javascript">
        function show_popup() {
            var pop = window.createPopup()
            var popbody = pop.document.body
   = "lime"
   = "solid black 1px"
            popbody.innerHTML = 
              "I am the pop-up, Click outside to close."
  , 150, 200, 50, document.body)
        <button onclick="show_popup()">


Note: The Window createPopup() Method works before Internet Explorer 11.

Supported browser:

  • Google Chrome: NO
  • Mozilla Firefox: NO
  • Edge: NO
  • Opera: NO
  • Safari: NO

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!