Forums / Basic Configuration / can't login to Admin after moving site

can't login to Admin after moving site

Locked

Views: 12,813

Results 1 to 15 of 15
This thread is locked. New replies are disabled.
6 Jan 2007, 8:36 PM
#1
yamcart avatar

yamcart

New Zenner

Join Date:
Aug 2006
Location:
Baltimore
Posts:
15
Plugin Contributions:
0

can't login to Admin after moving site

I can't login to the Admin after moving my ZenCart to another directory. When I try, I get just a white screen. :ohmy:

I had everything working, but my client changed the domain name. While adding the new domain name, I had trouble using the existing successful ZenCart directory for the new domain name, so I created a new directory for the new domain. Then I moved everything into the new directory, and the store works fine.

Trouble is, I can't login to the Admin to add new products, etc.

I looked all around in the Support Site, and found the suggestions below, and tried them all --

-=-=-=-

In most cases of difficulties logging in to the Admin area, the problem is one of:

  1. Admin pages won't show at all, or show without styling.
    In this case, try temporarily renaming the /admin/.htaccess file to htaccess_bak to see if things operate differently. If they do, then you need to work with your webhost to find the right way to use the supplied .htaccess security protections on your site.

  2. Something may be wrong with the way your site is configured to handle PHP "sessions".
    This is more difficult to resolve. Start by clearing your browser cache and clearing all cookies. Then check to be sure that you do NOT have any software firewall applications running on your PC, as they may have been set to "disable session cookies". Also, make sure your browser IS allowed to accept cookies, esp from your own domain. Check your server's errorlog to determine if any errors are occurring at the time of the failure to login.

  3. The most common problem is not having the HTTPS address correct in the includes/configure.php and admin/includes/configure.php

See: http://www.zen-cart.com/tutorials/index.php?article=14

If these suggestions don't work, note them, and post to the forum listing what steps you've already taken.

-=-=-=-

Okay, I tried all of those things. Also tried using the The Fix Cache Key utility.

Still have the same result -- the store works, but I can't login to Admin. I get just a white screen. :down:

Can anyone help with this?

I stink, therefore I am.

7 Jan 2007, 12:26 AM
#2
ajeh avatar

ajeh

Oba-san

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

Re: can't login to Admin after moving site

Go to phpMyAdmin and search the configuration table for the configuration_key:
SESSION_WRITE_DIRECTORY

Set that correctly

Next search for configuration_key:
SHOW_VERSION_UPDATE_IN_HEADER

try setting that to false in case your new server cannot handle it set to true ...

Next, edit the file:
/admin/includes/configure.php

Turn the enable secure to false for now ...

See if you can now login ...

If you still cannot, often times when you FTP your files to the site you can get errors that will cause mystery issues like this ...

Try reloading your files to the /admin and all of its subdirectories ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Jan 2007, 2:05 PM
#3
yamcart avatar

yamcart

New Zenner

Join Date:
Aug 2006
Location:
Baltimore
Posts:
15
Plugin Contributions:
0

Re: can't login to Admin after moving site

Thanks for the quick and detailed reply.

How can I go to phpMyAdmin? I don't know what that means. :blush:

Also, once I get to phpMyAdmin, your note says to set that correctly. I'm unsure what that means -- what would be correct, and what is incorrect for that?

The next part I can do -- I can edit the file: /admin/includes/configure.php and turn the enable secure to false for now. That would be done with a text editor, then re-upload the file to the server.

But I don't know about the first part of your message. :unsure:

Sorry to seem too dumb to help. Can you please clarify what I must do?

Thanks...

I stink, therefore I am.

8 Jan 2007, 2:21 PM
#4
ajeh avatar

ajeh

Oba-san

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

Re: can't login to Admin after moving site

phpMyAdmin is a program that allows you to see your database tables and the content ...

This is available via your web site Control Panel, often called CPanel ...

Check with your hosting site if you are unsure how to find this ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

8 Jan 2007, 6:55 PM
#5
yamcart avatar

yamcart

New Zenner

Join Date:
Aug 2006
Location:
Baltimore
Posts:
15
Plugin Contributions:
0

Re: can't login to Admin after moving site

Hello Ajeh,

Thanks for the help. I have tried everything you suggested, but to no avail. On login attempt, I still get a blank white screen.

I had used phpMyAdmin to verify the correct path for SESSION_WRITE_DIRECTORY. I also set SHOW_VERSION_UPDATE_IN_HEADER to false. Then I edited /admin/includes/configure.php to turn the enable secure to false. Also, I reloaded all files and all subdirectories to the /admin directory, using FTP.

This is weird. Everything had been working fine. Now, with just four days to launch, I suddenly can't edit the store. :blink:

By the way, I didn't move from one server to another, just copied files within one server from one directory to another. This was all precipitated by my customer's last minute request to change to a new domain name.

Perhaps I should ask my question in a different way --

If I have a working Zen-Cart, all set, but I want to move it into a different directory which is accessed by a separate domain name of its own, how should I proceed?

Thanks for all your help... :thumbsup:

I stink, therefore I am.

8 Jan 2007, 8:14 PM
#6
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,668
Plugin Contributions:
0

Re: can't login to Admin after moving site

Please post your includes/configure.php minus your password.

Please do not PM for support issues: a private solution doesn't benefit the community.

Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

8 Jan 2007, 8:18 PM
#7
yamcart avatar

yamcart

New Zenner

Join Date:
Aug 2006
Location:
Baltimore
Posts:
15
Plugin Contributions:
0

Re: can't login to Admin after moving site

Hello again,

Searching for anything relevant in other threads, I found and tried this stuff, below, which you had written for another user in mid-October:

-=-=-=-

Close all browser windows
Clear your cache and cookies

Go into phpMyAdmin and EMPTY the tables for:
db_cache
sessions
whos_online

Reset the admin table with:
PHP Code:
DROP TABLE IF EXISTS admin;
CREATE TABLE admin (
admin_id int(11) NOT NULL auto_increment,
admin_name varchar(32) NOT NULL default '',
admin_email varchar(96) NOT NULL default '',
admin_pass varchar(40) NOT NULL default '',
admin_level tinyint(1) NOT NULL default '1',
PRIMARY KEY (admin_id),
KEY idx_admin_name_zen (admin_name),
KEY idx_admin_email_zen (admin_email)
) TYPE=MyISAM;
PHP Code:
INSERT INTO admin VALUES (1, 'Admin', 'admin@localhost', '351683ea4e19efe34874b501fdbf9792:9b', 1);
This will set the login to: Admin with the password admin

XXX-- Go to Tools ... Admin Settings ... XXX
XXX-- Change your login, password and email address ... XXX

-=-=-=-

Now, the old password doesn't work and says "You entered the wrong password." That's good -- it lets me know the changes were implemented.

When I enter the new username/password I get the same thing -- a blank-screen white window. Tried to View Source and got the same thing -- a blank-screen white window.

Whatever is wrong is at least consistenly wrong, since I get the same result with the new passwod after dumping the db_cache, sessions and whos_online, but that doesn't help me.

I need to be able to edit the store via the web interface. :down:

Should I start from scratch, download and build a new store, then move all the stuff from the old store into the new store? If so, is there a clever way to do it, that can streamline the process and minimize the work?

Thanks for your help. :mellow:

I stink, therefore I am.

8 Jan 2007, 8:20 PM
#8
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,668
Plugin Contributions:
0

Re: can't login to Admin after moving site

Please do what I asked above.

Please do not PM for support issues: a private solution doesn't benefit the community.

Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

8 Jan 2007, 8:23 PM
#9
yamcart avatar

yamcart

New Zenner

Join Date:
Aug 2006
Location:
Baltimore
Posts:
15
Plugin Contributions:
0

Re: can't login to Admin after moving site

Sorry about that, I didn't see your post. It must have posted while I was writing mine.

Below is my configure.php file.

-=-=-=-

<?php /** * * @package Configuration Settings * @copyright Copyright 2003-2006 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://www.zen-cart.com/license/2_0.txt> GNU Public License V2.0 */ // Define the webserver and path parameters // HTTP_SERVER is your Main webserver: eg, <http://www.yourdomain.com> // HTTPS_SERVER is your Secure webserver: eg, <https://www.yourdomain.com> define('HTTP_SERVER', 'http://filmheadimagery.com'); define('HTTPS_SERVER', 'https://filmheadimagery.com'); // Use secure webserver for checkout procedure? define('ENABLE_SSL', 'false'); // NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes! // * DIR_WS_* = Webserver directories (virtual/URL) // these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder) define('DIR_WS_CATALOG', '/'); define('DIR_WS_HTTPS_CATALOG', '/'); define('DIR_WS_IMAGES', 'images/'); define('DIR_WS_INCLUDES', 'includes/'); define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/'); define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/'); define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/'); define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/'); define('DIR_WS_DOWNLOAD_PUBLIC', DIR_WS_CATALOG . 'pub/'); define('DIR_WS_TEMPLATES', DIR_WS_INCLUDES . 'templates/'); define('DIR_WS_PHPBB', '/'); // * DIR_FS_* = Filesystem directories (local/physical) //the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/ define('DIR_FS_CATALOG', '/home2/wildycom/public_html/filmhead/'); define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/'); define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/'); define('DIR_WS_UPLOADS', DIR_WS_IMAGES . 'uploads/'); define('DIR_FS_UPLOADS', DIR_FS_CATALOG . DIR_WS_UPLOADS); define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/'); // define our database connection define('DB_TYPE', 'mysql'); define('DB_PREFIX', 'zen_'); define('DB_SERVER', 'localhost'); define('DB_SERVER_USERNAME', 'XXXXXXXX'); define('DB_SERVER_PASSWORD', 'XXXXXXXX'); define('DB_DATABASE', 'XXXXXXXX'); define('USE_PCONNECT', 'false'); // use persistent connections? define('STORE_SESSIONS', 'db'); // use 'db' for best support, or '' for file-based storage // The next 2 "defines" are for SQL cache support. // For SQL_CACHE_METHOD, you can select from: none, database, or file // If you choose "file", then you need to set the DIR_FS_SQL_CACHE to a directory where your apache // or webserver user has write privileges (chmod 666 or 777). We recommend using the "cache" folder inside the Zen Cart folder // ie: /path/to/your/webspace/public_html/zen/cache -- leave no trailing slash define('SQL_CACHE_METHOD', 'database'); define('DIR_FS_SQL_CACHE', '/home2/wildycom/public_html/filmhead/cache'); ?>

-=-=-=-

Thanks in advance for any help... :p

I stink, therefore I am.

9 Jan 2007, 7:27 PM
#10
yamcart avatar

yamcart

New Zenner

Join Date:
Aug 2006
Location:
Baltimore
Posts:
15
Plugin Contributions:
0

Re: can't login to Admin after moving site

I still need help with the problem noted below. :cry:

Did I do something wrong, to get myself shunned or ignored in this thread? :wacko:

I stink, therefore I am.

9 Jan 2007, 9:57 PM
#11
drbyte avatar

drbyte

Sensei

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

Re: can't login to Admin after moving site

Now, the old password doesn't work and says "You entered the wrong password." That's good -- it lets me know the changes were implemented.

When I enter the new username/password I get the same thing -- a blank-screen white window. Tried to View Source and got the same thing -- a blank-screen white window.

So, to summarize, the problem essentially boils down to this:

  1. if you enter an invalid username+password, you get an error message.
  2. if you enter a correct username+password, you get a blank screen.
    Please correct me if I'm missing anything there.

Most likely you've ended up with some file in the /admin/includes area being corrupted during your move.
I would suggest downloading a full copy of your admin section, perhaps even your entire site since the admin section also uses files from other areas not limited to just the admin.
Then compare that downloaded copy with the master "working" copy that you have on your PC, using a tool like WinMerge.
This should quickly expose the cause of the problem. Maybe it's a blank file, or a file that ended up getting double-spaced for some reason, etc.

Essentially, a variation on this:
http://www.zen-cart.com/wiki/index.php/Troubleshoot_-_Diagnosing_Obscure_Issues

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

9 Jan 2007, 9:59 PM
#12
drbyte avatar

drbyte

Sensei

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

Re: can't login to Admin after moving site

yamcart:

I still need help with the problem noted below. :cry:

Did I do something wrong, to get myself shunned or ignored in this thread? :wacko:

Shunned? no.
Simple questions usually get faster answers. Yours is not simple. Especially when the usual things haven't worked.
The nature of a volunteer support system is that if someone doesn't have an answer, they usually move on to the next question, saying nothing.
Sorry yours got missed.
Best way to counter that is to keep adding more information if possible.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

8 Mar 2007, 3:48 PM
#13
chrisc avatar

chrisc

New Zenner

Join Date:
Oct 2006
Posts:
3
Plugin Contributions:
0

Re: can't login to Admin after moving site

I have a similar problem to the one just summerized.

When I logon using Admin admin, the correct user id and password, I get bounced back to the Admin Login screen with no error message. I use an incorrect user id and password I get the appropriate error message.

I have done the following:

  • used the "Resend Password" option
  • dropped the tbl_admin table and recreated it
  • inserted the default Admin login as presented in a previous post
  • I used Winmerge to compare the current files with the original installed code and found no corruption or blank files.I still have the same problem
10 Mar 2007, 3:53 PM
#14
ajeh avatar

ajeh

Oba-san

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

Re: can't login to Admin after moving site

Could you post your file, from the server, without your username or password for:
/admin/includes/configure/php

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

11 Nov 2010, 3:06 PM
#15
vadimzven avatar

vadimzven

New Zenner

Join Date:
Aug 2009
Posts:
26
Plugin Contributions:
0

Re: can't login to Admin after moving site

I got the same situation, when I transfer my website to another hosting. I wasn't able to login in admin area and I didn't receive any messages except wrong user name or password. I spent a lot of time to changing user name/password and finally I decided to install zen cart to the different directory, but using the same admin name and pwd. The name of DB I'm also created also the same, just added number after name. After that I changed configure.php in a admin/include . Next step - open phpMyAdmin (new DB) and copy from zen_admin table encrypted admin password to the old DB.
And finally I just remove new installation, new DB and change pwd from Admin Store config.