15 มี.ค. 2563

How to change Joomla Admin Folder Name or Path

That changing the folder name ‘administrator’ to ‘myadmin” & change the , 
 
     define( ‘JPATH_ADMINISTRATOR’, JPATH_ROOT.DS.’administrator’ );  to
     define( ‘JPATH_ADMINISTRATOR’, JPATH_ROOT.DS.’myadmin’ );

In the ‘includes->defines.php’ & ’administrator->includes->defines.php’ doesn create some problem in thired party component.

So finally I found another trick which work for me, is as below.

1. Create a new directory in your root directory (eg. “myadmin”)
2. Create an index.php file in your “myadmin” directory..

<?php
      $admin_cookie_code=”999999999″;
      setcookie(“JoomlaAdminSession”,$admin_cookie_code,0,”/”);
      header(“Location: ../administrator/index.php”);
?>


3. Add this to the beginning of index.php in real administrator folder
#administrator/index.php (modify , **do not replace**)
 
if ($_COOKIE['JoomlaAdminSession'] != “999999999″){
     header(“Location: ../index.php”);
}