Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

AHHH HELP ME


luckygirrl

Recommended Posts

my site was fine and now i get this fatal error message when i try to view a product info.

 

Fatal error: Cannot redeclare tep_db_connect() (previously declared in /home/dsvmout/public_html/includes/functions/database.php:13) in /home/dsvmout/public_html/includes/functions/database.php on line 13

 

i tried to restore the databse and i still get the error. i even uploaded the roiginal product info files inc ase they got corrupt, but now everything is messed up...what do di do??? this needs to be fixed now because the site goes live in 2 DAYS!! please help me i will forever be in your debt

 

you can see what i mean by going to www.nattieb.com

Link to comment
Share on other sites

I see what you mean about the error - maybe the vars it references are corrupted or not set somewhere else?

 

or maybe a URL fault or a syntax error - have you edited the file in question or installed a contribution before this happened?

Link to comment
Share on other sites

i did try a contribution but it didnt work, so i put the old files back, then i kept working on other stuff and suddenly this doesn't work. if i messed something up i cant figure out what. i assume it must be the product_info.php file since that is when i get the error. all the rest of the pages work fine.

i found this in the knowledge base

 

Cannot redeclare tep_db_connect Last Update: 6th April, 2005

Article ID: 198

Introduction

Solution

 

The following error message is shown when a main code file has been uploaded to the languages directory by accident.

 

Cannot redeclare tep_db_connect() (previously declared in /home/username/public_html/store/includes/functions/database.php:13)

 

Solution

 

Upload the correct file to the languages/*/ directory where * is the name of the language you are using.

 

 

------

so i went and copied all the original files into the languages directory and still nothing. i also tried to restore my database like 3 times and it shows it restoring but i still get this stupid error...im totally at a loss for what to do next. i dont want to have to start all over.

Link to comment
Share on other sites

Ah - is there an extra file now found in the languages dir that has a duplicate declaration in it - that isnt one of the standard set? That would explain it.

 

Delete all files in the dir and re-upload the original ones unless you can spot the file and delete it by itself.

 

My lang dir has only language files in it - english.php, german.php etc nothing else.

Link to comment
Share on other sites

Try this if you cant find an extra file in there - comment the function out in database.php by putting // at the start of the line, then save the file.

 

If that works, the function has been declared already somewhere else and can't be declared again. You can always remove the // later if you find the rogue file.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...