How to create a webPush Notification On Blogger or Wordpress


      Hi friends today i am Going To tech you How to create a webpush notification for your Blogger or Wordpress

Why Use Webpush Notification

Now a day Subscribe by email box is Getting old and people Don't like These Boxes Because No one have time to submit a Email and so on

   So now have developed the web push Notification that allow your users to Subscribe your by Just clicking on allow button so toady we are Going to Use this Script

<script>
// request permission on page load
document.addEventListener('DOMContentLoaded', function () {
  if (Notification.permission !== "granted")
    Notification.requestPermission();
});

function notifyMe() {
  if (!Notification) {
    alert('Desktop notifications not available in your browser. Try Chromium.');
    return;
  }

  if (Notification.permission !== "granted")
    Notification.requestPermission();
  else {
    var notification = new Notification('Notification title', {
      icon: 'http://cdn.sstatic.net/stackexchange/img/logos/so/so-icon.png',
      body: "Hey there! You've been notified!",
    });

    notification.onclick = function () {
      window.open("https://usamabutt789.blogspot.com");   
    };

  }

}
</script>



 How to Install this script



check this video to learn How to Intsall webpush notification script