Forums / General Questions / help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

Locked

Started by jschrodt1 on 11 Dec 2009, 11:09 PM · Views: 1,007

Results 1 to 9 of 9
This thread is locked. New replies are disabled.
11 Dec 2009, 11:09 PM
#1
jschrodt1 avatar

jschrodt1

New Zenner

Join Date:
Dec 2009
Posts:
5
Plugin Contributions:
0

help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

Hi,

we just recently had our host upgrade php on us...

we were at 4.4.4 and not having any trouble with the store, the host upgraded us to 5.2.11 and then when we were getting errors they downgraded us to 4.4.6 and are unable to return us to version 4.4.4

we are still getting errors...

we're running a mostly plain jane install of zencart 1.2.5d (I know its way old... we're planning on upgrading after the holiday season, hopefully to 2.0)

when anyone goes to the site it gives us the error "
Fatal error: Call to undefined function: get_template_dir() in /home/talonarm/public_html/t a l o n a r m s/includes/languages/english/credit_cards.php on line 57"

you can see the error at http://t a l o n a r m s .com/t a l o n a r m s/index.php

also when we log into the admin area it gives us a similar error for another file, "Fatal error: Call to undefined function: preg_match() in /home/talonarm/public_html/t a l o n a r m s/admin/includes/boxes/catalog_dhtml.php on line 44"

the url for that one is http://www.t a l o n a r m s.com/t a l o n a r m s/admin/configuration.php?gID=1&vcheck=yes but you wont be able to see it since its in the admin area.

I have compared the files and lines listed in the errors and they appear to match.

anyone have any ideas on how to get it working on 4.4.6? or where we can get source code for version 4.4.4?(I looked and couldnt find it anywhere)

Thanks!

11 Dec 2009, 11:18 PM
#2
drbyte avatar

drbyte

Sensei

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

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

Zen Cart v1.2.5 is perfectly compatible with PHP 4.2 through 4.4.9.
If you want to upgrade to PHP 5.2, you'll need to upgrade your version of Zen Cart to at least v1.3.7.1
If you want to upgrade to PHP 5.3, you'll need to upgrade to at least v1.3.8a and apply the PHP 5.3 patch for v1.3.8a.

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

11 Dec 2009, 11:19 PM
#3
drbyte avatar

drbyte

Sensei

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

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

JSchrodt1:

Fatal error: Call to undefined function: preg_match() in ...

preg_match() is a function that's part of options built-in to PHP. If that's throwing an "undefined function" error, then your hosting company hasn't compiled PHP with posix support. Only they can fix that for you.

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

11 Dec 2009, 11:22 PM
#4
drbyte avatar

drbyte

Sensei

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

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

JSchrodt1:

when anyone goes to the site it gives us the error "
Fatal error: Call to undefined function: get_template_dir() in ...
That suggests that one or more files on your site has been damaged, or if files were moved or removed and replaced then maybe one or more files didn't get transferred properly.

Start by double-checking that all the files in the /includes/classes and /includes/functions folders are 100% intact and the file contents are 100% correct. If the problem persists after fixing those, then double-check all the rest of the files on your server.

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

12 Dec 2009, 12:04 AM
#5
jschrodt1 avatar

jschrodt1

New Zenner

Join Date:
Dec 2009
Posts:
5
Plugin Contributions:
0

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

Thanks for the suggestions. I'll ask the host to recompile with posix support, and start going over the includes files.

12 Dec 2009, 2:19 AM
#6
jschrodt1 avatar

jschrodt1

New Zenner

Join Date:
Dec 2009
Posts:
5
Plugin Contributions:
0

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

compiling posix into php didnt seem to have any effect.

had 2 files show up slightly different in includes/classes - they were shopping_cart.php and template_func.php

changed them back to what they were in the original.... now getting a different error at the catalog...
Fatal error: Call to undefined function: preg_replace() in /home/talonarm/public_html/t a l o n a r m s /includes/functions/functions_general.php on line 1253

still getting the same error in the admin area...

12 Dec 2009, 2:26 AM
#7
drbyte avatar

drbyte

Sensei

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

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

Oops ... I should have said PCRE, not posix, although having posix isn't a bad thing.

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

12 Dec 2009, 2:44 AM
#8
jschrodt1 avatar

jschrodt1

New Zenner

Join Date:
Dec 2009
Posts:
5
Plugin Contributions:
0

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

I'll ask them to add it as well, hopefully it will fix it.

12 Dec 2009, 3:49 AM
#9
jschrodt1 avatar

jschrodt1

New Zenner

Join Date:
Dec 2009
Posts:
5
Plugin Contributions:
0

Re: help recovering from host upgrading to PHP 5.2, running Zen Cart v1.2.5

looks like that has brought us back up. thanks!

definitely need to do the upgrade still.

Thanks again!