We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 28042 ☆ A M B ☆
    • 24,524 Posts
    I have hacked the entire core to allow a custom manager directory name. The setting needs to be made in one place, at the very beginning of the main index.php file.
    if (!defined('MANAGERDIR')) {define('MANAGERDIR', 'customdirname');}
    

    Your config.inc.php file also needs adjusting to use the new constant value:
    if (!defined('MODX_MANAGER_PATH')) define('MODX_MANAGER_PATH', $base_path.MANAGERDIR.'/');
    if (!defined('MODX_MANAGER_URL')) define('MODX_MANAGER_URL', $site_url.MANAGERDIR.'/');
    


    This has not been done for the installer or for plugins and modules yet.

    If anyone is interested in working with this, here is the modified manager (minus the config.inc.php file). The modified index.php.zip file is the main index.php file, which also needs to be replaced (and the MANAGERDIR constant defined to match your manager’s directory name).
      Studying MODX in the desert - http://sottwell.com
      Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
      Join the Slack Community - http://modx.org
      • 25663 MODX Staff
      • 12,272 Posts
      Excellent Susan!

      Would love to see this in a future release once complete. What’s the potential for third party add-on breakage you think, e.g., for someone who’s hard-coded "manager/" in their code somewhere?

      Which version was this based on?
        Ryan Thrash, MODX Co-Founder
        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
        • 28042 ☆ A M B ☆
        • 24,524 Posts
        I’m afraid third-party add-ons with the manager directory hard-coded would be badly broken. Basically all I did was replace every reference to manager/ with the constant. That constant is manually defined in the front-end index.php file, but I used some code based on dirname(__FILE__) to establish the value for the manager index.php file and the login processor .php file.

        I downloaded the latest from svn to do this; 1.1 something or another.

        I don’t see any way of "fixing" third-party addons, short of editing each one. It’s a pity I didn’t bring this up years ago the first time I did this; we’ve had all those years of third-party development since then piling up. I’ll be working on the default installed addons in the next day or so, as well as the install files so that the config.inc.php file won’t need further editing. Eventually I would like to be able to have this be a value selected at installation. There’s no getting around setting it in the main index.php file, though, since it’s needed there to get at a few included files, and it can’t be determined programmatically as it can from any files within the manager directory.
          Studying MODX in the desert - http://sottwell.com
          Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
          Join the Slack Community - http://modx.org
          • 25663 MODX Staff
          • 12,272 Posts
          <unofficial opinion>
          I really think the config file should be in the /assets directory or maybe even the site root, which would keep the /manager free to blow out for upgrades.
          </unofficial opinion>

          But, Revo migrations and keeping things in sync with Revo should take first priority for any theoretical change like this.
            Ryan Thrash, MODX Co-Founder
            Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me