Zen Cart Logo
Forums / General Questions / Can't login to admin

Can't login to admin

Locked

Views: 50,599

Results 101 to 120 of 165
This thread is locked. New replies are disabled.
17 Oct 2008, 4:04 PM
#101
ajeh avatar

ajeh

Oba-san

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

Can't login to admin

Could you post, from the server, the file:
/admin/includes/configure.php

without your username and password ...

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!

16 Nov 2008, 11:36 AM
#102
speeke avatar

speeke

Zen Follower

Join Date:
Jul 2004
Posts:
65
Plugin Contributions:
0

Re: Can't login to admin

I have recently transferred a Zen Cart install (v1.3.5) from one computer to another (both installs are on a local server). The new computer is a MacBook Pro with MAMP installed. All went well (green ticks etc), and I have no trouble accessing the catalog, but cannot access Admin - I enter a user/pass combo, and keep getting the same login screen. If I enter a wrong combo, the login page shows the appropriate error message.

I have tried myriad solutions as suggested on the forum - all to no avail, for example:

  1. deleting browser cookies/cache etc
  2. changing browser (I have tried FF, Safari, Opera and Camino)
  3. resetting admin user/passwords
  4. deleting whos_online table data
  5. trying the session_regenerate_id() code
    etc ...

I have used the fix_cache_key.php - all is well there.

I access my server from http://localhost:8888/, and I keep all my websites in the /Users/speeke/Sites folder - I altered the Apache section of MAMP's user preferences to suit.

I have a copy of my techsupp.php details, but the file is too long to include in this message. If required, please let me know how I may send a copy.

I would really appreciate if someone could suggest a fix, as I am now at a complete loss. :(

BTW: I do not want to upgrade the install as it mirrors the live site, and I am not the owner of the site.

16 Nov 2008, 3:46 PM
#103
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,843
Plugin Contributions:
17

Re: Can't login to admin

Is there a winmerge for Mac?

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

16 Nov 2008, 10:29 PM
#104
speeke avatar

speeke

Zen Follower

Join Date:
Jul 2004
Posts:
65
Plugin Contributions:
0

Re: Can't login to admin

Hi dbltoe,

Are you directing your question to me? If so, what is winmerge?

17 Nov 2008, 3:29 AM
#105
speeke avatar

speeke

Zen Follower

Join Date:
Jul 2004
Posts:
65
Plugin Contributions:
0

Re: Can't login to admin

Update ...

I have found the following error in my php error log:

[17-Nov-2008 14:19:51] PHP Fatal error: Call to a member function Execute() on a non-object in /Users/username/Sites/website/products/includes/functions/sessions.php on line 61

Can anyone please help resolve why this error is occurring?

17 Nov 2008, 5:59 AM
#106
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,843
Plugin Contributions:
17

Re: Can't login to admin

Yes, Speeke, I was addressing you.

Your original description sounded like you might have had a bad transfer from the old server to new. Hence the winmerge question. You hinted at the fact you might be using a Mac. However , a google of winmerge would have taken you to their page and found that there is a winmerge for Mac and what it does for comparing files.

Taking the error that you got from the error log and using it to search the forum, would have gotten you to http://www.zen-cart.com/forum/showpost.php?p=287588&postcount=5 which takes you to http://www.zen-cart.com/forum/showthread.php?p=287587#post287587.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

17 Nov 2008, 6:50 AM
#107
speeke avatar

speeke

Zen Follower

Join Date:
Jul 2004
Posts:
65
Plugin Contributions:
0

Re: Can't login to admin

Many thanks, dbltoe.

I should have searched the forum for that error :blush: - thank you for directing me there.

It has fixed one of my installs, but not an older version (which, once again I am not in a position to upgrade as I don't own the shop). This one is v1.2.6.

Do you know of a workaround for this?

Cheers :smile:

17 Nov 2008, 4:01 PM
#108
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,843
Plugin Contributions:
17

Re: Can't login to admin

I would inform the owner of the many holes in that version plus the fact it will probably not run with the newer PHP and won't run with the newer MySQL.

Searching Google for Zen Cart PHP compatibility comes up with http://www.zen-cart.com/forum/showthread.php?t=72869

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

17 Nov 2008, 5:10 PM
#109
yenmax avatar

yenmax

New Zenner

Join Date:
Sep 2006
Posts:
89
Plugin Contributions:
0

Re: Can't login to admin

Hi,
I have bee reading the threads but I can not found my problems. I know my server was doing maintenance but after that I can not open my http://www.yenmax.com/admin and my checkout page is not working either. So please help me, this is extremely frustrating! Thank you so much!

13 Feb 2009, 3:28 PM
#110
seanymph avatar

seanymph

New Zenner

Join Date:
Aug 2008
Location:
Sydney Australia
Posts:
58
Plugin Contributions:
0

Re: Can't login to admin

Hi there,
I have zen cart 1.3.8a installed and I am using The Bookshelf template. I have added contact sidebox, ezpages on sitemap, spruce up your administration Loging Screen and enhanced whos online modules.

Everything was working ok until I was booted off the admin panel for some unknown reason.

Now I can not get back into the admin panel through internet explorer however, I have no problems getting into the admin panel with Firefox.

I have cleared all cookies and cache from my browsers.

Can someone please tell me what the problem is and how I can fix it.

13 Feb 2009, 5:17 PM
#111
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,843
Plugin Contributions:
17

Re: Can't login to admin

Without a link to your site, we can only guess.

You might try entering your admin link in the W3C validator to see if there are any errors that would affect IE.

You can also view the page source in IE to try and determine where the admin index stops loading.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

3 Mar 2009, 5:10 PM
#113
davn8r avatar

davn8r

New Zenner

Join Date:
Jul 2008
Posts:
1
Plugin Contributions:
0

Re: Can't login to admin

I just created a fresh install of 1.3.8a and have been having similar login problems in the admin area - I use the correct password and username and the page simply refreshes.
I was able to resolve using the recommended 'admin/includes/local/configure.php' recommendation earlier in this thread (define('SESSION_RECREATE', 'False');).

My client is looking to switch from a previous oscommerce install so I am trying zen and I would like to know if there is a specific production-ready fix I can make for this problem.

Am I correct in assuming that I should not go live with the workaround in place? If so what is the correct methodology for fixing my issue properly?

My configuration is:

Webserver = Apache/2.0.46 (Red Hat)
PHP 4.3.2
MySQL 3.23.58 (I know - incredibly old - maybe I should switch hosters)

Thanks in advance for any assistance.

3 Mar 2009, 5:46 PM
#114
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,843
Plugin Contributions:
17

Re: Can't login to admin

davn8r:

I just created a fresh install of 1.3.8a and have been having similar login problems in the admin area - I use the correct password and username and the page simply refreshes.
I was able to resolve using the recommended 'admin/includes/local/configure.php' recommendation earlier in this thread (define('SESSION_RECREATE', 'False');).

My client is looking to switch from a previous oscommerce install so I am trying zen and I would like to know if there is a specific production-ready fix I can make for this problem.

Am I correct in assuming that I should not go live with the workaround in place? If so what is the correct methodology for fixing my issue properly?

My configuration is:

Webserver = Apache/2.0.46 (Red Hat)
PHP 4.3.2
MySQL 3.23.58 (I know - incredibly old - maybe I should switch hosters)

Thanks in advance for any assistance.You answered your own question.
New 2.0 (when out) will require PHP 5.2 and MySql 4.+

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

3 Mar 2009, 8:08 PM
#115
drbyte avatar

drbyte

Sensei

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

Re: Can't login to admin

davn8r:

I was able to resolve using the recommended 'admin/includes/local/configure.php' recommendation earlier in this thread (define('SESSION_RECREATE', 'False');).
You'll recall that there is specific warning against using that in a live environment: http://www.zen-cart.com/forum/showpost.php?p=421231&postcount=44

davn8r:

My client is looking to switch from a previous oscommerce install so I am trying zen and I would like to know if there is a specific production-ready fix I can make for this problem.

Am I correct in assuming that I should not go live with the workaround in place? If so what is the correct methodology for fixing my issue properly?

My configuration is:

Webserver = Apache/2.0.46 (Red Hat)
PHP 4.3.2
MySQL 3.23.58 (I know - incredibly old - maybe I should switch hosters)
There are 2 factors to a "production-ready" "fix":

  1. use a current version of PHP. Yours is ancient and is no longer supported by the PHP authors. I'm not surprised that you're having session problems if the server is that outdated and clearly unmaintained.
  2. use the latest published version of Zen Cart with all published patches applied to it

As dbltoe mentioned, you clearly need to upgrade your webserver if you want to avoid future headaches.

If you're considering changing hosting companies, there is a list of recommended Hosts available via a link at the top of this page.

.
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.

19 Mar 2009, 9:42 AM
#116
twinge avatar

twinge

New Zenner

Join Date:
Jun 2005
Posts:
36
Plugin Contributions:
0

Re: Can't login to admin

Oi, looks like I get to give this thread yet another bump up. I think I've found my answer, but this answer disturbs me greatly so I'm hoping for an alternative ;) To be specific, I'm getting the same issue with the admin login page merely going back to itself, whether a correct login is supplied or not. It also appears that I can't make a new customer account either. This is an old install that work working fine at least through most of January, and just recently stopped working. Pertinent info:

  • Site: https://www.justbetees.com
  • Host: Dreamhost
  • Secure settings in configure files turned off
  • PHP: 5.2.6
  • MySQL: 5.0.16
  • ZenCart Version: Ancient (Somewhere between 1.2.4 and 1.3.0.1, probably closer to the former -- 5/11/06 timestamp on files, so a version at that time or older)

I'm pretty sure my issue is the last two bullet points there - I read that Pre-1.3 versions do not work properly with MySQL 5. I know the obvious suggestion would be to upgrade, but I'd REALLY like to avoid this if possible; a lot of the site's design and code has been hack-jobbed through a variety of different files and I believe I'd basically be starting from scratch on an upgrade - which is time I really can't afford to spend right now. My plan was to just tough it out with my ancient version until 2.0 came along and then start fresh then :/

Anyway, if this is indeed the likely problem... any suggestions for some quick hacky fixes I might be able to implement, to keep the site live and running for another few months? (I don't think I can switch back to MySQL 4; DH had posted that all new databases were going to be 5, and all old ones would stay 4 as long as they reasonably could. This was posted sometime 8/2008.) Or, other ideas of what it might be if that's not definitely the problem?

19 Mar 2009, 4:33 PM
#117
townsend2009 avatar

townsend2009

New Zenner

Join Date:
Nov 2008
Posts:
93
Plugin Contributions:
0

Re: Can't login to admin

[QUOTE=Twinge;702270

  • Host: Dreamhost
  • Secure settings in configure files turned off
  • PHP: 5.2.6
  • MySQL: 5.0.16
  • ZenCart Version: Ancient (Somewhere between 1.2.4 and 1.3.0.1, probably closer to the former -- 5/11/06 timestamp on files, so a version at that time or older)[/QUOTE]

Yesterday my cart was working fine. Today I can't login. The admin page does nothing, won't login, won't send a password, won't do anything. I noticed you host with Dreamhost. I also host with them and wonder if something happened last night???

19 Mar 2009, 7:17 PM
#118
ajeh avatar

ajeh

Oba-san

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

Re: Can't login to admin

There are various things that going to php 5 and MySQL 5 break down on in old versions of Zen Cart ...

Some of these threads can help:

http://www.zen-cart.com/forum/showthread.php?t=37460&highlight=join+upgrade

http://www.zen-cart.com/forum/showthread.php?t=25174

There is also a change that helps on php 5 for the two session.php functions ...

Note the change here specific to php 5:

    function _sess_write($key, $val) {
      global $db;
      if (!is_object($db)) {
        //PHP 5.2.0 bug workaround ... 
        $db = new queryFactory();
        $db->connect(DB_SERVER, DB_SERVER_USERNAME, DB_SERVER_PASSWORD, DB_DATABASE, USE_PCONNECT, false);
      }

      global $SESS_LIFE;

There are probably other threads on this ... but these should help a lot ...

Also get the Debug Tool from the Free Software Add Ons ... as it can help identify them ...

The main issue is the SELECT statements and how they are constructed that need updating ...

Note: do those session function files first or you won't get real far if already in php 5 ... :smile:

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!

19 Mar 2009, 7:19 PM
#119
twinge avatar

twinge

New Zenner

Join Date:
Jun 2005
Posts:
36
Plugin Contributions:
0

Re: Can't login to admin

townsend2009:

Yesterday my cart was working fine. Today I can't login. The admin page does nothing, won't login, won't send a password, won't do anything. I noticed you host with Dreamhost. I also host with them and wonder if something happened last night???

This has been an issue for me for at least ~3 weeks or so - it didn't just happen last night. However, if Dreamhost is gradually forcing databases to become MySQL 5 over the course of several weeks, then it might be a related issue - especially if you also have an older version of ZC.

19 Mar 2009, 7:53 PM
#120
twinge avatar

twinge

New Zenner

Join Date:
Jun 2005
Posts:
36
Plugin Contributions:
0

Re: Can't login to admin

Ajeh:

There is also a change that helps on php 5 for the two session.php functions ...
(code)

Note: do those session function files first or you won't get real far if already in php 5 ... :smile:

Quite - it looks like I already made this change a year and a half ago to the main sessions.php file. I don't actually remember doing it, hehe. Dreamhost must've force-switched to PHP5 a long while back, but maybe forcing MySQL 5 is only recent? Today I put this fix in the admin sessions file too, though it would appear that it was working on PHP5 without it for quite some time.

Ajeh:

Some of these threads can help:

http://www.zen-cart.com/forum/showthread.php?t=37460&highlight=join+upgrade

http://www.zen-cart.com/forum/showthread.php?t=25174

I'll start reading through then, thanks. This is kind of a hard problem to search for; I tried a couple different terms and read through a lot of threads already, hehe.

Ajeh:

Also get the Debug Tool from the Free Software Add Ons ... as it can help identify them ...

I forgot to mention that I had already done this last night as well - in both the admin and general sections. No log files were showing up (and I did make sure the cache folder was set to 777).

Checking it now, though, there are some log files present, all with the same error:

[19-Mar-2009 01:43:43] PHP Fatal error: Call to a member function Execute() on a non-object in /xxxx/xxxx/xxxx/xxxx/includes/functions/sessions.php on line 72

And this is the entire relevant function how it looks now, with line numbers (starting at 1; I notice line 72 is blank, so perhaps the line numbers should start at 0?):

**xxxx/includes/functions/sessions.php**

61       function _sess_write($key, $val) {
62   
63         global $db;
64   // The following is only to work around a PHP 5.2.0 bug:
65         if (!is_object($db)) {
66           $db = new queryFactory();
67           $db->connect(DB_SERVER, DB_SERVER_USERNAME, DB_SERVER_PASSWORD, DB_DATABASE, USE_PCONNECT, false);
68         }
69           //PHP 5.2.0 bug workaround ... 
70   
71         global $SESS_LIFE;
72   
73         $expiry = time() + $SESS_LIFE;
74         $value = $val;
75   
76         $qid = "select count(*) as total
77                 from " . TABLE_SESSIONS . "
78                 where sesskey = '" . zen_db_input($key) . "'";
79   
80         $total = $db->Execute($qid);
81   
82         if ($total->fields['total'] > 0) {
83           $sql = "update " . TABLE_SESSIONS . "
84                   set expiry = '" . zen_db_input($expiry) . "', value = '" . zen_db_input($value) . "'
85                   where sesskey = '" . zen_db_input($key) . "'";
86   
87           return $db->Execute($sql);
88   
89         } else {
90           $sql = "insert into " . TABLE_SESSIONS . "
91                   values ('" . zen_db_input($key) . "', '" . zen_db_input($expiry) . "', '" .
92                            zen_db_input($value) . "')";
93   
94           return $db->Execute($sql);
95   
96         }
97       }

Perhaps I implemented the fix incorrectly? It's been somehow working for most of the last year and a half this way, though ;P