Hey guys I'm trying to integrate payment gateway in my website so they have send me a code but I'm quite new to javascript now they have send code working with <body> tag and I want to use this code with <div> tag:-
<script>
    var hash = '<?php echo $hash ?>';
    function submitPayuForm() {
      if(hash == '') {
        return;
      }
      var payuForm = document.forms.payuForm;
      payuForm.submit();
    }
  </script>
executing function like this:-
<body onload="submitPayuForm()">
How does it possible with or something else.
<div onload="submitPayuForm()">