Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

includes/languages/.php is not working


genesissystem

Recommended Posts

Posted

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/includes/application_top.php on line 285

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/includes/application_top.php on line 285

 

Fatal error: main(): Failed opening required 'includes/languages/.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/rejoi/public_html/includes/application_top.php on line 285

 

note: the file english.php is inside of (includes/languages/english.php)

 

Please help...........

Carlos

I can do everything through him who gives me strength. (Philippians 4:13)

Posted

If you have been modifying includes/application_top.php you may have deleted some code or it may have been corrupted during upload.

 

Lines 284 and 285 should look like this:

 

// include the language translations
 require(DIR_WS_LANGUAGES . $language . '.php');

 

Check to see it is like that.

Posted
Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/includes/application_top.php on line 285

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/includes/application_top.php on line 285

 

Fatal error: main(): Failed opening required 'includes/languages/.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/rejoi/public_html/includes/application_top.php on line 285

 

note: the file english.php is inside of (includes/languages/english.php)

 

Please help...........

 

from the looks of it don't quote me it looks like includes/languages/.php should be includes/languages.php therefor take out the "/" after languages on line 285 of the application_top.php file. I'm sure that is what it is but I usually have to do it myself to test it.

 

Hope that helps :D

Posted
If you have been modifying includes/application_top.php you may have deleted some code or it may have been corrupted during upload.

 

Lines 284 and 285 should look like this:

 

// include the language translations
 require(DIR_WS_LANGUAGES . $language . '.php');

 

Check to see it is like that.

 

Hello

I have exacly as you say

 

// include the language translations

require(DIR_WS_LANGUAGES . $language . '.php');

 

also the web was working perfect I don not why this is happen

Carlos

I can do everything through him who gives me strength. (Philippians 4:13)

Posted
Hello

I have exacly as you say

 

// include the language translations

require(DIR_WS_LANGUAGES . $language . '.php');

 

also the web was working perfect I don not why this is happen

 

I'm guessing you didn't read my post :D :thumbsup:

Posted

I fought this problem recently myself. Fixed it, but I'm not totally sure which thing I did fixed it.

 

I had made a number of modifications that day.

 

Incidentally, you can probably get in to your store temporarily by typing www.yourstore.com/(catalog)/index.php?language=en

 

Then if you click any links you'll probably get a funky error.

 

Have you done any editing to application top, application bottom, or any .htaccess files?

 

I was convinced at some point that it was a session/cookie problem for me, or a weird redirect that couldn't complete for some reason (related to the seo url contribution that I had added just the day before).

 

I reset and/or turned off all of my seo url stuff, turned off all of the caching, removed some suspicious code that I had added to app top (and app bottom) ...then it was magically fixed. Turned it all back on one by one...and no problems since.

 

In some of the old threads I read, some people said that they could clear their browser cookies, shut down their browser, then temporarily get back into the store. Very strange. That didn't work for me.

 

Just a lot of nonsense ideas and no real solution, sorry. Hope some of it might be of some use. :blush:

 

PS your application top lines re. $language look fine to me. Your error is identical to what I had.

Posted

I still have the same problem..............

 

can somebody helpme.........................

 

 

note: shortd81 you subjestion dont work.................thanks

 

 

can somebody helpme.........................PLEASEEEEEEEEEEEE

Carlos

I can do everything through him who gives me strength. (Philippians 4:13)

Posted

This problem is not usually caused by a problem with your code but a problem with your database.

 

This line

main(includes/languages/.php):

 

should really read as

 

main(includes/languages/english.php):

 

The language choice is set in the datbase but is not getting set properly. Populate the database in phpmyadmin from your last backup and that should fix the problem.

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Posted
This problem is not usually caused by a problem with your code but a problem with your database.

 

This line

main(includes/languages/.php):

 

should really read as

 

main(includes/languages/english.php):

 

The language choice is set in the datbase but is not getting set properly. Populate the database in phpmyadmin from your last backup and that should fix the problem.

 

thanks for you help

 

where do I change this........?

main(includes/languages/.php):

 

and where in the DB I change the language choice ...?

Carlos

I can do everything through him who gives me strength. (Philippians 4:13)

Posted
thanks for you help

 

where do I change this........?

main(includes/languages/.php):

 

and where in the DB I change the language choice ...?

 

When this problem shows up you are going to have other problems as well because your database is not populated properly. This is just the first one to show up.

 

If this is an existing store go to your phpmyadmin and import your last backup. If this is a new install then use the oscommerce.sql file to populate your database manually

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Posted
When this problem shows up you are going to have other problems as well because your database is not populated properly. This is just the first one to show up.

 

If this is an existing store go to your phpmyadmin and import your last backup. If this is a new install then use the oscommerce.sql file to populate your database manually

 

I delete the DB and install againg and is working fine, but went I up load the Data from the old DB

i get the same problem*********what I do now***********

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

Fatal error: main(): Failed opening required 'includes/languages/.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

Carlos

I can do everything through him who gives me strength. (Philippians 4:13)

Posted
I delete the DB and install againg and is working fine, but went I up load the Data from the old DB

i get the same problem*********what I do now***********

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

Fatal error: main(): Failed opening required 'includes/languages/.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

 

The data you uploaded is obviously not any good. You need to use the last backup you have from when your store was working correctly.

The Knowledge Base is a wonderful thing.

Do you have a problem? Have you checked out Common Problems?

There are many very useful osC Contributions

Are you having trouble with a installed contribution? Have you checked out the support thread found Here

BACKUP BACKUP BACKUP!!! You did backup, right??

Posted
I delete the DB and install againg and is working fine, but went I up load the Data from the old DB

i get the same problem*********what I do now***********

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

Warning: main(includes/languages/.php): failed to open stream: No such file or directory in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

Fatal error: main(): Failed opening required 'includes/languages/.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/rejoi/public_html/shopping/includes/application_top.php on line 285

 

check the languages table and make sure that it has an entry like:

 

languages_id | name | code | image | directory | sort_order

1 | English | en | icon.gif | english | 1

I thought this stuff was gonna be easy!!

BACK IT UP BEFORE YOU JACK IT UP!!!!

Posted
The data you uploaded is obviously not any good. You need to use the last backup you have from when your store was working correctly.

 

my last backup

was working correcly by I thing was a diffent version of oscommere

also where I donwload oscommerce.sql ...?

Carlos

I can do everything through him who gives me strength. (Philippians 4:13)

Posted

Do some error checking. Find this in includes/application_top.php

 

	if (isset($HTTP_GET_VARS['language']) && tep_not_null($HTTP_GET_VARS['language'])) {
  $lng->set_language($HTTP_GET_VARS['language']);
} else {
  $lng->get_browser_language();
}

 

Just under paste this code:

 

		if ( !tep_not_null($lng->language) ){
		$lng->language = $lng->catalog_languages[DEFAULT_LANGUAGE];
	}

Posted
Do some error checking. Find this in includes/application_top.php

 

	if (isset($HTTP_GET_VARS['language']) && tep_not_null($HTTP_GET_VARS['language'])) {
  $lng->set_language($HTTP_GET_VARS['language']);
} else {
  $lng->get_browser_language();
}

 

Just under paste this code:

 

		if ( !tep_not_null($lng->language) ){
		$lng->language = $lng->catalog_languages[DEFAULT_LANGUAGE];
	}

 

 

I put exacly as you say and is not working

Im running crazy...............please help

Carlos

I can do everything through him who gives me strength. (Philippians 4:13)

Posted

echo DEFAULT_LANGUAGE;

 

It sounds like you have an issue with your catalog languages.

Posted

Everyone makes valid points...I might have missed this one, but do you get this error on both sides (catalog and admin) ...or can you get into the admin panel?

Archived

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

×
×
  • Create New...