Forums / General Questions / I trashed my configure.php file. How do I recover?

I trashed my configure.php file. How do I recover?

Locked

Views: 2,042

Results 1 to 11 of 11
This thread is locked. New replies are disabled.
29 Nov 2007, 3:51 AM
#1
john_vieth avatar

john_vieth

New Zenner

Join Date:
Oct 2007
Posts:
42
Plugin Contributions:
0

I trashed my configure.php file. How do I recover?

I accidentally trashed my configure.php file by overwriting it with the dist-configure.php file that I renamed configure.php. (I'm stupid.) Now the store is acting like I need to do an install, but that will wipe out all my data. Is there any way I can reconfigure the configure.php file so that it uses all of my existing files and database tables? Please advise.

Thanks,
John

29 Nov 2007, 4:11 AM
#2
ajeh avatar

ajeh

Oba-san

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

Re: I trashed my configure.php file. How do I recover?

You could replace it from your backup copy ... :smile:

Oh ... I get it ... not backup copy ... :eek:

You could piece back together by viewing the contents of the:
/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!

29 Nov 2007, 4:12 AM
#3
chuck avatar

chuck

Totally Zenned

Join Date:
Jul 2005
Posts:
255
Plugin Contributions:
0

Re: I trashed my configure.php file. How do I recover?

That's where your backups come in handy ... you do make backups, don't you? Especially before you make changes, right? And again after making your changes ... right?

And you backup your database daily too, right? Just so you have a quick way to recover if anything were to go wrong.

Ajeh's right -- you'll find some good reference info in your admin configure.php file. Don't copy it exactly though... just use it as a reference.

29 Nov 2007, 5:18 AM
#4
john_vieth avatar

john_vieth

New Zenner

Join Date:
Oct 2007
Posts:
42
Plugin Contributions:
0

Re: I trashed my configure.php file. How do I recover?

But the /admin/includes/configure.php file got overwritten, too, so I can't use that as a reference.

I overwrote both configure.php files because I was trying to turn on SSL. So I grabbed the dist-configure.php files and used those. Don't ask me what I was thinking. It's been a long day. :-)

There has to be some way to manually type the correct settings in those files and re-upload them. I have everything re-typed and uploaded, but the index.php page still redirects to zc_install/index.php.

What gives? All my settings and products should be in my database, and all my other stuff should be in my includes directory. Wiping out configure.php couldn't have wiped out my whole site and forced a re-install, could it? I don't want to have to re-install.

Is there anyway that I can tell what is making Zen Cart think that the configure.php file is not right?

Please help!

  • John
29 Nov 2007, 5:21 AM
#5
drbyte avatar

drbyte

Sensei

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

Re: I trashed my configure.php file. How do I recover?

Your data's all in your database, so none of that info would be lost unless you did something to wipe it out.

YOU SHOULD DO A DATABASE BACKUP ASAP ... just in case ...

John Vieth:

Is there anyway that I can tell what is making Zen Cart think that the configure.php file is not right?

There are 3 possible causes:
a) configure.php file doesn't exist
b) DIR_FS_CATALOG setting is incorrect in the file, or any of the paths referenced from it.
c) any of the DB_XXXXXXX settings are incorrect

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

29 Nov 2007, 5:23 AM
#6
ajeh avatar

ajeh

Oba-san

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

Re: I trashed my configure.php file. How do I recover?

Something I suggest ... which will (kinda) rebuild your configure.php files for you ...

Do a quick install into the directory:
/goober

into the database;
iama

and now you have some nice, shiny new configure.php files that you can use and just change the paths ... :cool:

Just ... DO NOT use the same database for this install as your existing install's database.

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!

29 Nov 2007, 5:39 PM
#7
john_vieth avatar

john_vieth

New Zenner

Join Date:
Oct 2007
Posts:
42
Plugin Contributions:
0

Re: I trashed my configure.php file. How do I recover?

You're a life saver. That worked! Turned out I had manually rebuilt the configure.php files correctly except one line that I just overlooked. I knew what to put in that line, but I overlooked it. Once I installed a test website and used that new configure.php file as a guide, I quickly found the one line that I had overlooked. All's well that ends well.

Thanks,
John

4 Dec 2007, 5:40 AM
#8
ajeh avatar

ajeh

Oba-san

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

Re: I trashed my configure.php file. How do I recover?

Thanks for the update that this worked for you ... :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!

11 May 2010, 6:51 AM
#9
realk2_llc avatar

realk2_llc

New Zenner

Join Date:
May 2010
Posts:
3
Plugin Contributions:
0

Re: I trashed my configure.php file. How do I recover?

i trashed my configure file too.. im not sure what to do i didnt make a back up and i will do it next time.. I am still able to login to my admin area but when i go directly to the url it says "oops page not found".. what should i do!

11 May 2010, 1:19 PM
#10
ajeh avatar

ajeh

Oba-san

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

Re: I trashed my configure.php file. How do I recover?

Could you say how you trashed your configure.php files or is that what you are not sure about?

Can you get to either your Catalog or your Admin?

If you go to your site does it break right away or not until the first click?

What version of Zen Cart are you in?

Are you on a unix or windows server?

What do your current configure.php files look like, without your password, from the server:
/includes/configure.php
/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 May 2010, 1:46 PM
#11
merlinpa1969 avatar

merlinpa1969

Totally Zenned

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

Re: I trashed my configure.php file. How do I recover?

I havnt seen the installer for a while but wasnt there a way to ONLY upgrade the config files using the zc_install

Zen cart PCI compliant Hosting