The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

WHM Plugin Step By Step Tutorial

Discussion in 'cPanel Developers' started by carbotex, Oct 24, 2013.

  1. carbotex

    carbotex Registered

    Joined:
    Oct 24, 2013
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi,

    We are currently evaluating CPanel 11.38.2 (build 11). In our application, we need to able to create a WHM plugin. We have successfully create a CPanel plugin by following the documentation, however the documentation on WHM is very unclear. Do you have a basic Hello World example on developing WHM plugin which include how to register the plugin and how to create a basic front end?

    Thanks,
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,834
    Likes Received:
    672
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
  3. Kheang

    Kheang Member

    Joined:
    Apr 25, 2014
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi, I tried going through this step by step:

    https://documentation.cpanel.net/display/SDK/AppConfig

    And I do not know where I am supposed to see my plugin appear.
    I looked under Plugins in WHM but it doesn't show.
    When I access the path directly when logged in using /3rdparty/sc_plugins/sc_create_user.php, my Hello World is displayed.
    But I can't seem to locate the icon where to access it via WHM.

    My .conf file contains this:

    # This is the name that will be displayed for your application in WHM.
    displayname=SC

    # service that will serve this app
    service=whostmgr

    # Physical path: /usr/local/cpanel/3rdparty/Foo.php
    # Literal URL path: $server:$port/$cpsession/3rdparty/Foo.php
    url=/3rdparty/sc_plugins/sc_create_user.php

    # Directory containing php.ini
    # - must exist in /usr/local/cpanel/3rdparty/etc/
    #phpHandler=Foo

    # Features required
    features=any

    # This is a comma-separated list of ACLs. The logged-in user must have at least one of these ACLs in order to access your application at the URL(s) provided.
    acls=all

    # This is the filename of the icon that is used by the application (For example: myapp_icon.png).
    icon=sc_icon.jpg


    What am I missing? My WHM is version WHM 11.42.1 (build 12)

    Thanks!
     
  4. Kheang

    Kheang Member

    Joined:
    Apr 25, 2014
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Ok so I was able to get it to appear in the Plugins area by copying the fantastico plugin. I had to use the old method.
    Using the AppConfig did not work for me at all.
     
Loading...

Share This Page