Forums / Basic Configuration / Rename Admin folder

Rename Admin folder

Locked

Views: 21,017

Results 1 to 20 of 40
This thread is locked. New replies are disabled.
16 May 2007, 19:59
#1
axip avatar

axip

New Zenner

Join Date:
Apr 2007
Posts:
30
Plugin Contributions:
0

Rename Admin folder

Hello I recently uploaded all the zencart files to my host.

But my host already has a default folder named admin for my site configuration(MySQL Db, Users etc)

Can I rename the zencart admin folder or does this takes/causes too much modifications/problems?

Or should I install the shop in a subdomain and redirect from the mainpage to the subdomain(will this work btw?)

16 May 2007, 20:04
#2
merlinpa1969 avatar

merlinpa1969

Totally Zenned

Join Date:
Mar 2004
Posts:
13,031
Plugin Contributions:
1

Re: Rename Admin folder

you can change the admin folder name after install,

02 Jun 2007, 18:12
#3
axip avatar

axip

New Zenner

Join Date:
Apr 2007
Posts:
30
Plugin Contributions:
0

Re: Rename Admin folder

I changed the admin folder according to this tutorial

http://www.zen-cart.com/wiki/index.php/Important_Site_Security_Recommendations

But I keep getting this error, I tried it a 100 times.

*Not Found

The requested URL /ADMiNx200/login.php was not found on this server. *

02 Jun 2007, 19:47
#4
dbrewster avatar

dbrewster

Zen Follower

Join Date:
Jul 2005
Location:
Charlottesville, VA
Posts:
376
Plugin Contributions:
0

Re: Rename Admin folder

Axip,

I think that error is telling you something important.

Check your configuration file and the exact name of the new admin folder to make sure that it is all exactly correct. Be sure you are typing in the correct path, too.

---Diana

03 Jun 2007, 11:40
#5
axip avatar

axip

New Zenner

Join Date:
Apr 2007
Posts:
30
Plugin Contributions:
0

Re: Rename Admin folder

I did, I even took over the path of the tutorial and searched in the config file.

Tried different names everything.

But my host already has a default folder named admin for my site configuration(MySQL Db, Users etc), maybe this is causing problems?

Can I try changing the names before install and see how that works?

03 Jun 2007, 12:04
#6
econcepts avatar

econcepts

Totally Zenned

Join Date:
Dec 2005
Posts:
1,505
Plugin Contributions:
1

Re: Rename Admin folder

axip:

I did, I even took over the path of the tutorial and searched in the config file.

Tried different names everything.

But my host already has a default folder named admin for my site configuration(MySQL Db, Users etc), maybe this is causing problems?

Can I try changing the names before install and see how that works?

No, the fact that your host already has a folder called "admin" does not matter. I have numerous sites running on hosts that have an "admin" folder and it makes no difference when you rename as long as you set your paths in the config file correctly (make sure you have included all the trailing slashes, and you do not need to actually reference the file in the url ... just the path to the directories will do).

The process is:

  1. Rename the admin folder
  2. Change the proper lines in the admin config file.
  3. Change the proper lines in the catalog config file.
03 Jun 2007, 13:04
#7
axip avatar

axip

New Zenner

Join Date:
Apr 2007
Posts:
30
Plugin Contributions:
0

Re: Rename Admin folder

Wait a minute, the tutorial doesn't say anything about a catalog config file, only a admin config file, maybe that's the issue? Could you give me details on how to edit the catalog config file?

03 Jun 2007, 13:33
#8
axip avatar

axip

New Zenner

Join Date:
Apr 2007
Posts:
30
Plugin Contributions:
0

Re: Rename Admin folder

Here I posted everything I changed here. This is obvioulsy the changes done in the admin/includes/configure.php file

*define('DIR_WS_ADMIN', '/admin/'); define('DIR_WS_CATALOG', '/'); define('DIR_WS_HTTPS_ADMIN', '/admin/'); define('DIR_WS_HTTPS_CATALOG', '/');

define('DIR_FS_ADMIN', '/var/www/html/admin/'); define('DIR_FS_CATALOG', '/var/www/html/');*

I changed this into this:

  • define('DIR_WS_ADMIN', '/axcd2/'); define('DIR_WS_CATALOG', '/'); define('DIR_WS_HTTPS_ADMIN', '/axcd2/'); define('DIR_WS_HTTPS_CATALOG', '/');

define('DIR_FS_ADMIN', '/var/www/html/axcd2/'); define('DIR_FS_CATALOG', '/var/www/html/');*

But I still get the error?

03 Jun 2007, 15:31
#9
axip avatar

axip

New Zenner

Join Date:
Apr 2007
Posts:
30
Plugin Contributions:
0

Re: Rename Admin folder

Alright, I disabled SSL and now its working.

03 Jun 2007, 20:12
#10
econcepts avatar

econcepts

Totally Zenned

Join Date:
Dec 2005
Posts:
1,505
Plugin Contributions:
1

Re: Rename Admin folder

axip:

Alright, I disabled SSL and now its working.

Glad to hear that.

For future reference to your question about the "Catalog config" file, open that file up /includes/configure.php and look for the SSL switches as well as the Admin switches. It looks identical (for the most part) to the one found in the Admin.

Simply make sure your paths there match to those (where applicable of course) in the Admin config file.

16 Jul 2007, 10:50
#11
milelk avatar

milelk

New Zenner

Join Date:
May 2007
Posts:
19
Plugin Contributions:
0

Re: Rename Admin folder

Hi, I have a similar problem and I don't understand the error message. I changed the name of my admin folder following the instructions in the tutorial. I tried changing it back when i got the error but I still get...

Warning: require(../../zen-cart-v1.3.7-full-fileset-12302006/admin/includes/application_top.php) [function.require]: failed to open stream: No such file or directory in /home/windowam/public_html/store/admin/index.php on line 23

Warning: require(../../zen-cart-v1.3.7-full-fileset-12302006/admin/includes/application_top.php) [function.require]: failed to open stream: No such file or directory in /home/windowam/public_html/store/admin/index.php on line 23

Fatal error: require() [function.require]: Failed opening required '../../zen-cart-v1.3.7-full-fileset-12302006/admin/includes/application_top.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/windowam/public_html/store/admin/index.php on line 23

What does this mean?? Please help!

16 Jul 2007, 11:04
#12
milelk avatar

milelk

New Zenner

Join Date:
May 2007
Posts:
19
Plugin Contributions:
0

Re: Rename Admin folder

Do I need to go into the application_top.php file and change the path name or something?

16 Jul 2007, 14:11
#13
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Rename Admin folder

You are showing two paths: /zen-cart-v1.3.7-full-fileset-12302006/admin

/store/admin

You need the paths to be correct and match in both: /includes/configure.php /admin/includes/configure.php

/admin can be whatever name you want but they need to match ...

17 Jul 2007, 05:08
#14
milelk avatar

milelk

New Zenner

Join Date:
May 2007
Posts:
19
Plugin Contributions:
0

Re: Rename Admin folder

Thanks Ajeh, I really appreciate your response to my post. I will try to do as you suggest, but I'm not sure where the reference to 'admin' is in one of the configure.php file... I think its includes/configure.php. I'm not at home right now but I'll check tonight and post with how it goes.

I think I've got those 'zen cart' paths in almost every file so will I need to change the names in every file? The first time I changed my admin folder name, dreamweaver updated the relevant paths and I think maybe this error has come about because of that? I'm not sure thought cos I didn't look at the path names before I made the changes.

17 Jul 2007, 05:12
#15
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
174

Re: Rename Admin folder

milelk:

The first time I changed my admin folder name, dreamweaver updated the relevant paths

That's a bad thing. Don't let it do that. The ONLY place you should see your admin folder path is in your /admin/includes/configure.php file.

17 Jul 2007, 10:52
#16
milelk avatar

milelk

New Zenner

Join Date:
May 2007
Posts:
19
Plugin Contributions:
0

Re: Rename Admin folder

DrByte:

That's a bad thing. Don't let it do that. The ONLY place you should see your admin folder path is in your /admin/includes/configure.php file.

Crapples. Then I have a lot of work ahead of me! The file which my error references application_top.php has this path "'../../../zen-cart-v1.3.7-full-fileset-12302006/admin/includes/includes/local/configure.php'" in it several times. What should I remove from the path to correct it?

I think this has happened in a lot of files. Damn Dreamweaver! I clicked ok to that path update by reflex and am suffering the consequences!

Regarding my earlier post... I cannot see reference to my admin folder path in my inlcludes/configure.php, only the 'store' path. From your comment about the other configure.php file being the only one to see the admin path I think I can say that thats ok.

17 Jul 2007, 11:04
#17
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
174

Re: Rename Admin folder

Do you have a backup of your files from before you started this procedure ?

17 Jul 2007, 12:38
#18
milelk avatar

milelk

New Zenner

Join Date:
May 2007
Posts:
19
Plugin Contributions:
0

Re: Rename Admin folder

Sadly no. hits head on keyboard, hence a lot of work. If I know what to replace the path with I can use the find and replace tool on each file though. That should save some time

18 Jul 2007, 00:20
#20
milelk avatar

milelk

New Zenner

Join Date:
May 2007
Posts:
19
Plugin Contributions:
0

Re: Rename Admin folder

Thanks for the tip DrByte! I'll give that a go when I get home tonight and post how it goes :D