b2evolution b2evolution

  • Sign in
  • Sign up
  • About
  • Downloads
  • Hosting
  • Docs
  • Support
  • Sign in
  • Sign up
  • Manuals Home
  • Latest Updates
 
  1. b2evolution CMS User Manual
  2. Operations Reference
  3. Security
  4. How to change the location of admin.php

How to change the location of admin.php

When moving the dispatcher file or admin.php from its default location in the root of the application to a sub-folder we will need to change the admin interface dispatcher configuration and we may also need to update the dispatcher file itself.

To change the admin interface dispatcher, edit your /conf/_advanced.php file and search for the the line which look similar to the following:

$dispatcher = 'admin.php';

Change the above configuration to reflect the new location and possibly name of the dispatcher file. For example, if you moved the admin.php file from application_path/ to application/subfolder then you should update the configuration to:

$dispatcher = 'subfolder/admin.php';

If you are using a _local.conf to override the admin interface dispatcher do not forget to also update the $admin_url configuration:

$dispatcher = 'subfolder/admin.php';
$admin_url = $baseurl.$dispatcher;

Next, if you moved the dispatcher file to a new location or subfolder then we will need to edit the dispatcher or admin.php file so it will know where to find the necessary configuration file /conf/_config.php.
Do this by editing the dispatcher file and search for the following line:

require_once dirname(__FILE__).'/conf/_config.php';

Update the above line to reflect the relative location of the /conf/_config.php. Using the earlier example, we moved the dispatcher to a new subfolder so the location of the configuration file should look like:

require_once dirname(__FILE__).'/../conf/_config.php';

If you simply renamed the dispatcher file and it is still located in the application root then editing the dispatcher file will not be necessary.

Created by winskie • Last edit by fplanque on 2019-12-01 02:00 • •

No feedback yet

Search the Manual

Content Hierarchy

  • b2evolution CMS User Manual
  • User's Guide
  • Installation / Upgrade
  • Front-office Reference
  • Back-office Reference
  • Developer Reference
  • Operations Reference
    • Security
      • File Permissions
      • Using SSL
      • Exposing PHP Errors to Visitors
      • Crumbs (nonces)
      • mod_security
      • .htaccess Files
      • Brute force password attacks
      • How to change the location of admin.php
    • Fighting Spam
    • Performance
    • Using Multiple Domains
    • Intranet setup
    • LDAP Integration
    • Troubleshooting
    • Bundled Plugins
  • Advanced Topics
  • Glossary
  • Archives
Multiple blogs done right!

This online manual is powered by b2evolution CMS – A complete engine for your website.

About b2evolution

  • What is it?
  • Features
  • Getting Started
  • Screenshots
  • Online demo
  • Testimonials
  • Design philosophy
  • Free & open source
  • Terms of service

Downloads

  • Latest releases
  • Skins
  • Plugins
  • Language packs

About us

  • About us
  • Contact

Webhosting Guide

  • Web hosting blog
  • Best web hosting
  • Cheap web hosting
  • Green web hosting
  • Hosting with SSH
  • VPS hosting
  • Dedicated servers
  • Reseller hosting
  • Int'l: UK / France

Docs & Support

  • Online manual
  • Forums
  • Hire a pro !

Other

  • Adsense
  • Press room
  • Privacy policy

Stay in touch

  • GitHub
  • Twitter
  • Facebook
  • LinkedIn
  • News blog
  • RSS feed
  • Atom feed

Founded & Maintained by François Planque