Move the FreePBX web interface to a subdomain

This is probably a simple question. I have a domain “” and our FreePBX is hosted on

But what I’d like to do is move the web UI over to so the main domain can host a WordPress website on the same box.

I’m using a ubuntu 20.04 non-distro install

Pointing me in the right direction would be enough. I tried searching for:

“move the FreePBX web interface to subdomain”

and I’m not having any luck with the results. Thanks!!

Without upsetting anything like signature checking, , there is

cat /var/www/html/index.php
//      License for all code of this FreePBX module can be found in the license file inside the module directory
//      Copyright 2013 Schmooze Com Inc.
if (file_exists(dirname(__FILE__) . '/index_custom.php')) {
        include_once(dirname(__FILE__) . '/index_custom.php');
} else {
        $basename = pathinfo($_SERVER['PHP_SELF'],PATHINFO_DIRNAME);
        $uri = (!empty($basename) && $basename != '/') ? $basename . '/admin' : '/admin';
        header('Location: '.$uri);

long story short , create a /var/www/html/index_custom.php that does what you want.

I appreciate your reply. Will give it some tinkering.

Wait. You want to use the same server for FreePBX and WordPress?

Why not?

1 Like

As long as the WordPress is a small informational website I don’t see any reason not to share a few resources with FreePBX. One less VPS to deal with.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.