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.

add an entry/application into the cpanel users main page

Discussion in 'cPanel Developers' started by nzin, Jun 18, 2013.

  1. nzin

    nzin Registered

    Joined:
    Jun 14, 2013
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi,

    I want to add an help "application" into the main page of cpanel users, in the "preferences" category.
    I was wondering how to do that. I use latest version of cpanel (WHM 11.38.0 (build 16))

    As far as I understood, I need to:
    - create a cPAddon
    - enable it in the feature manager
    - and insert it somewhere in the theme

    1/ create a cPAddon, directly on the server

    To create a cPAddon, I tried to follow the documentation, i.e.
    - I created this hierarchy under /usr/local/cpanel/cpaddons:
    * cPAddonsAvailable/MyCompany.pm
    * cPAddonsMD5/MyCompany.pm
    * MyCompany/Support/mycompanySupport.pm
    * MyCompany/Support/mycompanySupport/1.0.tar.gz
    * MyCompany/Support/mycompanySupport/upgrade/
    - I added an entry in cPAddonsConf.pm
    our %vend = (
    'MyCompany::Support::mycompanySupport' => { 'version' => 0, 'VERSION' => 0 },
    );

    - when done, I see an new entry in "Install cPAddons Site Software", but it is written MyCompany::Support::mycompanySupport", and not the description I put into MyCompany/Support/mycompanySupport.pm

    If I click on "Update Vendor", I get an error:
    Warning: Vendor List failed to be included: Can't locate cPAddonsAvailable/MyCompany/Support/mycompanySupport.pm in @INC (@INC contains: /usr/local/cpanel /usr/local/cpanel/whostmgr/docroot/cgi /usr/local/cpanel/cpaddons /usr/local/cpanel /usr/local/cpanel/3rdparty/perl/514/lib64/perl5/cpanel_lib/x86_64-linux-64int /usr/local/cpanel/3rdparty/perl/514/lib64/perl5/cpanel_lib /usr/local/cpanel/3rdparty/perl/514/lib64/perl5/5.14.3/x86_64-linux-64int /usr/local/cpanel/3rdparty/perl/514/lib64/perl5/5.14.3 /opt/cpanel/perl5/514/site_lib/x86_64-linux-64int /opt/cpanel/perl5/514/site_lib .) at (eval 51) line 1. BEGIN failed--compilation aborted at (eval 51) line 1.
    Contact MyCompany::Support::mycompanySupport for support.

    If I copy /usr/local/cpanel/cpaddons/MyCompany directory into /usr/local/cpanel/cpaddons/cPAddonAvailable, it works better, but it is not what is written in the documentation


    2/ enable it

    even after that, I want to make it appears in the user cpanel preferences pane, so I expect to enable it in in the "Feature Manager", but I don't see it. And I guess here it is not the correct way.



    So what did I missed?
    Thanks in advance


    Nicolas Zin
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,767
    Likes Received:
    662
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    The cPAddons system allows a script to be packaged up so that it can be installed on a user's website, upgraded, uninstalled and otherwise managed from cPanel and WebHost Manager. I believe you are actually seeking to develop a cPanel plugin. Plugins are documented at:

    Installing a cPanel Plugin

    Thank you.
     
  3. nzin

    nzin Registered

    Joined:
    Jun 14, 2013
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Great!

    That was what I was looking for.

    Thank you!
     
    #3 nzin, Jun 18, 2013
    Last edited: Jun 18, 2013
Loading...

Share This Page