Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

WHM Plugin PHP

Discussion in 'cPanel Developers' started by ChrisDeVe, Apr 18, 2018.

  1. ChrisDeVe

    ChrisDeVe Registered

    Joined:
    Apr 18, 2018
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    UK
    cPanel Access Level:
    Root Administrator
    Create a New WHM Interface in PHP

    I follow the tutorial on how to include Cpanel Header

    require_once('/usr/local/cpanel/php/WHM.php');

    WHM::header('Engintron for cPanel/WHM',1,1);


    Hides the interface's header.
    • Set this value to 1 to hide the header.
    • Set this value to 0 to display the header.
    It seems if you want to display you must set 1 not 0 so I'm confused here.

    The second issues I see all tabs from a navigation on left there are opened and is not saving every time one you refresh all tabs will be opened.

    Can you please guide us or me specialty what I'm doing wrong?

    Thank you
     
  2. ChrisDeVe

    ChrisDeVe Registered

    Joined:
    Apr 18, 2018
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    UK
    cPanel Access Level:
    Root Administrator
    Forgot to say this:

    On request header the small difference I saw is this.
    Code:
    <script>
    window.COMMON = window.COMMON || {};
    window.COMMON.leftNavNVData = {};
    </script>
    <script src="/templates/menu/command.min.js"></script>
    
    
    By default on the homepage on WHM, you will find like that
    
    <script>
    window.COMMON = window.COMMON || {};
    window.COMMON.leftNavNVData = {"whmcommand:Transfers":"0","whmcommand:Support":"0","whmcommand:Server_Configuration":"0","whmcommand:System_Reboot":"0","whmcommand:Service_Configuration":"0","whmcommand:SQL_Services":"0","whmcommand:Networking_Setup":"0","whmcommand:Themes":"0","whmcommand:Market":"0","whmcommand:cPanel":"0","whmcommand:Backup":"0","whmcommand:navigation":"0","whmcommand:Email":"0","whmcommand:Security_Center":"0","whmcommand:SSL_TLS":"0","whmcommand:DNS_Functions":"0","whmcommand:Locales":"0","whmcommand:Account_Information":"0","whmcommand:Clusters":"0","whmcommand:Packages":"0","whmcommand:Resellers":"0","whmcommand:Server_Status":"0","whmcommand:Restart_Services":"0","whmcommand:Plugins":"0","whmcommand:Development":"0","whmcommand:System_Health":"0","whmcommand:Server_Contacts":"0","whmcommand:Multi_Account_Functions":"0","whmcommand:Software":"0","whmcommand:IP_Functions":"0","whmcommand:Account_Functions":"0"};
    </script>
    <script src="/cPanel_magic_revision_1509995947/templates/menu/command.min.js"></script>
    
    
     
    #2 ChrisDeVe, Apr 18, 2018
    Last edited by a moderator: Apr 18, 2018
  3. cPanelLauren

    cPanelLauren Forums Analyst
    Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    1,804
    Likes Received:
    133
    Trophy Points:
    118
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice