Advertisement
Guest User

Untitled

a guest
Oct 12th, 2016
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.81 KB | None | 0 0
  1. function ispcfg3_ClientArea( $params ) {
  2. $soapsvrurl = $params['configoption3'];
  3. $soapsvrssl = $params['configoption4'];
  4.  
  5. if ( $soapsvrssl == 'on' ) {
  6.  
  7. $soapsvrurl = 'https://' . $soapsvrurl . '';
  8.  
  9. } else {
  10.  
  11. $soapsvrurl = 'http://' . $soapsvrurl . '';
  12.  
  13. }
  14.  
  15. $code = '
  16. <form id="frmIspconfigLogin" action="'.$soapsvrurl.'/index.php" method="GET" target="_blank">
  17. <button type="submit" class="btn btn-xs btn-success">CONTROLPANEL LOGIN</button>
  18. </form>
  19.  
  20. <script type="text/javascript">
  21. $("#frmIspconfigLogin").submit(function(){
  22. $.ajax({
  23. type: "POST",
  24. url: "'.$soapsvrurl.'/login/index.php",
  25. data: "s_mod=login&s_pg=index&username='.$params['username'].'&password='.$params['password'].'",
  26. xhrFields: {withCredentials: true}
  27. });
  28.  
  29. });
  30. </script>';
  31.  
  32. return $code;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement