Why using a plugin for that?
You can set a function to calculate the size of the 2 installations. The size of abc.com will include also the size of the other installation, but then you can subtract the smallest from the largest.
$path = ABSPATH;
$size = foldersize($path);
function folderSize ($dir)
{
$size = 0;
foreach (glob(rtrim($dir, "https://wordpress.stackexchange.com/").'/*', GLOB_NOSORT) as $each) {
$size += is_file($each) ? filesize($each) : folderSize($each);
}
return $size;
}
Related Posts:
- WordPress incorrectly redirects to local IP address?
- Migrating WordPress from Windows Server 2008 R2 (IIS v7.5) to CentOS
- Best practices for configuring a server?
- Minecraft Server closes immediately after running?
- WAMP vs XAMPP pros/cons – for running a local testing server [closed]
- WordPress local development environment [closed]
- Can you host WordPress using Amazon Web Services such as EC2, RDS, EBS etc?
- Character encoding issue after changing servers
- WordPress .htaccess subdirectory problem
- Implement ssl to a WP docker container [closed]
- security+best practices: root or www-data on a wordpress content folder?
- Apache/Linux configuration changes to make automatic upgrade more straightforward
- Testing local server with MAMP/wordpress on mobile device? [closed]
- Arabic Characters in URL returns 404 Error
- moving server can not login
- Connect to server with SFTP instead of FTP/FTPS within WordPress Backup
- WordPress hangs when I publish or update a post [closed]
- Force Cron to run only on one server
- Gutenberg: unable to save attributes with ServerRender
- Handling the response sent from a ruby on rails application in wordpress
- How might I setup a development server (local) and a test/production server (remote)
- Why does WordPress get posts from MySQL from a virtual hostname but not the direct hostname?
- Can you have multiple wordpress sites under the same domain?
- Can’t delete unwanted favicon
- How to Better Control WordPress Cron Jobs?
- Changing the server path
- Editing post and page responding 503 Service Unavailable
- Two live WP websites – how to sync?
- what are the chmod rights recommended to give for every folders of wordpress projects
- WordPress installation site folder move to the final site destination
- WordPress hosting optimized servers – Is this just a sales gimmick? [closed]
- External cron job firing too many times
- Does WP read itself?
- SSH Upgrade Problem
- Archived Server for Reference – Unable to Navigate Passed Homepage
- dev site running on subdomain is redirecting to the main domain
- copy wordpress site files on new server
- Lamp stack not supporting phpmyadmin? [closed]
- HTTP Error on media upload, only httpd restart helps
- Moving wordpress to an unknown outlet
- White screen on front page only
- Log Author Actions
- WordPress hosting moved from windows server to linux server
- WordPress backup(on another server)leading to old server addy and WP
- cURL error for cron
- WordPress sub-directory on other server running on nginx?
- Plugins & backup not working correctly on new Digital Ocean server
- Server specification [closed]
- How to change settings so I can upload images in WordPress posts?
- WordPress FTP via admin panel slow
- Scripts external to WordPress cause 404 errors
- WordPress PHP version/info not being picked from cPanel PHP Version values
- Changing domain name causes some strange problem in my browser
- Problems fixing a REST API 404 after Moving my WordPress Directory and updating Permalink Structure
- Sequence of finding a website when they are running WordPress
- i have a problem with my domain getting rederected to another one
- How to optimize wp_delete_post() function, or why it is so slow
- Adding a “code checker” for my e-learning wordpress site
- localhost/wordpress(or other application), how does it work?
- WordPress vps memory allocation
- Getting past the Synology default web site when creating a web server
- Internal Server Error after restoring MySQL databases
- Apache using full RAM problem
- Best WordPress Cloud Hosting Provider that allows installation of ffmpeg 4.0
- Server (VPS) is going down when editing a bigger wordpress article! (?)
- URL problem in my site
- Setting up WordPress client and server
- Formatting wordpress debug messages
- Multi-server environment is causing problems in WordPress
- Does WordPress perform better with curl installed?
- Folder Permissions + Security Concerns
- WordPress or plugin need tomcat?
- Trouble getting wordpress working after moving servers
- Apache extensions for WordPress’ working without troubles
- WordPress keeps crashing my server
- WordPress not working locally
- Would Amazon AWS Services be a good alternative to my current hosting provider?
- WordPress site causing lots of server IO
- What level of permissions should the plugins folder be set to?
- Download a zip folder of selected files
- Problems with ‘require (./xxx)’ on IIS7.5
- Moving a WordPress website from one server to another
- Test for IP in Array Always Fails on First IP
- Where can I find web hosting reviews? [closed]
- Will denying all ip address except my own create a problem?
- Reduce initial server response time wordpress
- Cannot connect to the Docker daemon at unix:/var/run/docker.sock. Is the docker daemon running?
- Amazon Linux: apt-get: command not found
- mysql_config not found when installing mysqldb python interface
- Linux error while loading shared libraries: cannot open shared object file: No such file or directory
- Shell command to tar directory excluding certain files/folders
- QEMU: /bin/sh: can’t access tty; job control turned off
- configure: error: cannot run C compiled programs
- What does set -e mean in a bash script?
- Shortest possible shell script to install WordPress on Nginx server?
- 418 header status, I’m a teapot [closed]
- Multisite on Rackspace Cloud (ubuntu lucid)
- User can not login
- Problems loading stylesheet and permalinks after rebooting
- Stuck downloading and extracting WordPress onto Ubuntu 22 LAMP server