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!

[Q]:showing bandwidth in the homepage?

Discussion in 'cPanel Developers' started by abdoh2010, Apr 23, 2005.

  1. abdoh2010

    abdoh2010 Active Member

    Joined:
    Jan 9, 2005
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    151
    Hi
    I thook about this a lot
    When I login in my cpanel I see the Bandwidth usage and I allows wandered
    Can it show by php code in the homepage of my website?
     
  2. brentp

    brentp Well-Known Member

    Joined:
    Mar 11, 2004
    Messages:
    324
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Ayr, North Queensland, Australia
    There are ways, but they are tricky. I'd try using it via perl, it works a LOT better. Check out the cPanel API for the full listing of tags you can use to get some info outta cpanel :).

    Regards,
    Brent
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. abdoh2010

    abdoh2010 Active Member

    Joined:
    Jan 9, 2005
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    151
    :D tricky is better
    It makes me feel that I’m doing something special

    I will see the API you refer to me
     
  4. abdoh2010

    abdoh2010 Active Member

    Joined:
    Jan 9, 2005
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    151
    Hay :eek:
    It’s a wide section
    I don’t know what they are talking about there :D
    Ok I have a cpanel and whm but I am an only user for them not a developer as I saw there
    So could you guide me to the one that I need it to do the job ;)
     
  5. abdoh2010

    abdoh2010 Active Member

    Joined:
    Jan 9, 2005
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    151
    I’m starting to read the documentation in this website and i found this
    http://cpanel.net/remoteaccess-php.html
    And
    http://www.cpanel.net/Modules-HOWTO.txt

    The first one is about php, and it is not useful to understand the story here by php

    The second one is by perl and I found in line 179
    "stats" = "View Account Statistics";

    I don’t know about this stuff but I think that it is related to what I’m searching for :D
    I will see that I can find out, but if you have any information will help me please let me know
     
  6. abdoh2010

    abdoh2010 Active Member

    Joined:
    Jan 9, 2005
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    151
    this is what i feger out :rolleyes:
    Code:
    #!/usr/bin/perl
    BEGIN {
            push(@INC,"/usr/local/cpanel");
            push(@INC,"/usr/local/cpanel/whostmgr/docroot/cgi");
    }
    use 'whmlib';
    require 'parseform.pl';
    
    use Cpanel::Accounting;
    
    if (!($ACL{'stats'} || $ACL{'all'})) {
    	print "Sorry permission denied to remove user";
    	exit();
    }
    "stats" = "View Account Statistics";
    i know that it's not complate but this is what i can do according to my zero understanding to perl :D
     
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