Jump to content

Whmcs Dbmanager | Free


Go to solution Solved by Slaweally,

Recommended Posts

Whmcs Dbmanager

Whmcs Dbmanager is an addon module for WHMCS that allows you to easily manage database tables, quickly clean log tables, perform bulk operations (export/clean/drop/optimize), and create full database backups.

Features

  • Table Listing and Size Display: Displays the sizes and record counts of the tables in the WHMCS database.
  • Default Cleanup Suggestions: Provides a suggestion list to quickly clean frequently growing log tables.
  • Bulk Operations: Select one or more tables and perform operations with a single click:
    • Export (Export, JSON)
    • Truncate
    • Drop
    • Optimize
  • Create New Table: Easily add a simple table.
  • Full Database Backup: Allows you to create a full database backup in .sql format using the mysqldump command. (Requires the exec() function and mysqldump support on your server.)

Installation

  1. Download the Files
    Obtain the whmcsdbmanager.php file (and any other files, if available) from this repository.

  2. Copy to the WHMCS Addon Directory
    In the root directory of WHMCS, follow this path:
    /path/to/whmcs/modules/addons/whmcsdbmanager/
    Place the whmcsdbmanager.php file inside modules/addons/whmcsdbmanager/.

    The directory structure should look like this:

    whmcs/
     └── modules/
         └── addons/
             └── whmcsdbmanager/
                 └── whmcsdbmanager.php
    
  3. Activate in the WHMCS Admin Panel
    Log into the Admin Panel: Setup > Addon Modules (or System Settings > Addon Modules).
    Find the "Whmcs Dbmanager" addon and click the Activate button.
    If necessary, click the Configure link to adjust the "Manage Access Control" settings (which admin roles can access it).

  4. Access the Addon Menu
    You will see the "Whmcs Dbmanager" option in the top menu under Addons > Whmcs Dbmanager.
    Click to run the module, view the table list, and perform bulk operations.

Usage

  • Table List: By default, 50 tables are displayed. You can change the number of records shown by selecting from 50, 100, 300, or 500 in the "Records to show" field at the top of the page.
  • Bulk Operations: Select one or more tables from the list and use the buttons for Export, Truncate, Drop, or Optimize.
    A confirmation modal will appear before the operation begins. Once you confirm, the page will refresh.
  • Default Cleanup Suggestions: A modal opens with selected log tables that tend to grow rapidly. You can select the tables you want and click the Clean Selected button to clean them quickly.
  • Create New Table: You can add a new table by typing the table name in the "Create new table" field.
  • Full Backup: Click the Full Backup button, confirm in the modal, and a full database backup will be created in .sql format.
    Important: This feature requires that the exec() function and mysqldump command are enabled on your server. If not, you will receive an error message.

Common Issues

  • Full Backup (exec() Error)
    If the exec() function is disabled or the mysqldump command is unavailable, the backup feature will not work.
    On shared hosting environments, the exec() function is often disabled for security reasons.

  • Table Drop/Truncate Permissions
    If you don't have the "DROP" or "TRUNCATE" permissions on the WHMCS database, the operation will fail.
    Please check your database user permissions or consult with your hosting provider.

  • Error Messages
    Most errors are displayed in an alert box at the top of the page. The addon works like a normal page within the WHMCS admin panel. If you're not allowed to drop a table, for example, you may see an error like "SQL Error."

Requirements

  • WHMCS 8+ (it may work on older versions, but theme differences or Bootstrap version issues may arise).
  • PHP 7.2+ (preferably 7.4 or 8.x).
  • For the "Full Backup" feature to work, the exec() function and mysqldump must be enabled on the server.

Contributing

  • Pull requests and issues are welcome!
    You can open an issue on GitHub for any improvements, bug fixes, or feature requests.

License

  • This addon is published under the MIT License.
    You can modify and distribute it as you like, but you must retain the license text.

Contact

Link to comment
Share on other sites

  • 2 weeks later...
1 hour ago, bear said:

And learn how to read in Turkish? Unless I've missed something, it's mostly in non-English.

I apologize, I made it for my own use, then I wanted everyone to use it and shared it, but I forgot to add the language 🙂

Now I translated it into English so everyone can use it

https://github.com/SLW-CMS/Whmcsdbmanager/

Link to comment
Share on other sites

1 hour ago, Gream Smith said:

Sure, Thanks for the update.  As you have added language option here, so it will be easy for all users to use it.

Thanks

I thank you for your nice comments. I uploaded it to GitHub so that anyone who wants to take it and develop and continue.
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated