Question: How can i integrate default whm theme (x) with custom whm plugin UI. I have tried following the guidance on
1)whm plugin - interface
2)create a new whm interface in template toolkit
When i run script index.cgi it gives me
"
Internal Server Error
500
No response from subprocess (/usr/local/cpanel/whostmgr/docroot/cgi/watch7/index.cgi): The subprocess reported error number 72,057,594,037,927,935 when it ended. The process dumped a core file.
cpsrvd Server at vps235171.example.com"
->main.tmpl
is using default script provided on Tutorial - Create a New WHM Interface in Template Toolkit - Developer Documentation - cPanel Documentation
->Below is my index.cgi script code
----------------------------------------------
1)whm plugin - interface
2)create a new whm interface in template toolkit
When i run script index.cgi it gives me
"
Internal Server Error
500
No response from subprocess (/usr/local/cpanel/whostmgr/docroot/cgi/watch7/index.cgi): The subprocess reported error number 72,057,594,037,927,935 when it ended. The process dumped a core file.
cpsrvd Server at vps235171.example.com"
->main.tmpl
is using default script provided on Tutorial - Create a New WHM Interface in Template Toolkit - Developer Documentation - cPanel Documentation
->Below is my index.cgi script code
----------------------------------------------
Code:
#!/bin/sh
eval 'if [ -x /usr/local/cpanel/3rdparty/bin/perl ]; then exec /usr/local/cpanel/3rdparty/bin/perl -x -- $0 ${1+"$@"}; else exec /usr/bin/perl -x $0 ${1+"$@"}; fi;'
if 0;
#!/usr/bin/perl
#WHMADDON:watch7:Watch7 - Instant Installs
use strict;
BEGIN { unshift @INC, '/usr/local/cpanel/whostmgr/docroot/cgi/watch7'}
use warnings;
use Whostmgr::ACLS ();
use Whostmgr::HTMLInterface ();
use Cpanel::Form ();
use Cpanel::Template ();
Whostmgr::ACLS::init_acls();
if (!Whostmgr::ACLS::hasroot())
{
print "Content-type: text/html\r\n\r\n";
print "You do not have access to LogView, Please contact your Server Adminitator.\n";
exit();
}
else
{
_headers("text/html");
my $template_file = '/usr/local/cpanel/whostmgr/docroot/templates/main.tmpl';
Cpanel::Template::process_template(
'whostmgr',
{
'template_file' => $template_file
},
);
}
# my $URL;
# if ( 'root' eq $ENV{'REMOTE_USER'} ){
# $URL = "../cgi/watch7/index.php";
# }else{
# $URL = "../cgi/watch7/index.cgi";
# }
# print "Location: $URL\n\n";
Last edited by a moderator: