Language File common.php coundn't be opened ?

Get help with installation and running phpBB 3.0.x here. Please do not post bug reports, feature requests, or MOD-related questions here.
Ideas Centre
Forum rules
END OF SUPPORT: 1 January 2017 (announcement)
phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Language File common.php coundn't be opened ?

Post by phpaaa » Sat Jan 03, 2009 7:25 am

just setup my phpbb3 forum and everything work very well. Yesterday i installed a chinese, japanese language pack. Then i clicked the "register" button and choose the board language to be chinese (not English) for TESTING, an error message appear

"Language file ./language/chinese/chinese/common.php couldn't be opened."

same situation appear when i chose "japanese" ... so that mean only English is working. Anything wrong ? I'm using the latest version of phpbb3 (installed anti-bot and rollover text MOD) and the language pack is downloaded from this site.

User avatar
ric323
Former Team Member
Posts: 22909
Joined: Tue Feb 06, 2007 12:33 am
Location: Melbourne, Australia
Name: Ric
Contact:

Re: Language File common.php coundn't be opened ?

Post by ric323 » Sat Jan 03, 2009 10:04 am

Are you sure you downloaded a phpBB3 language?
I think you may have a phpBB2 version.
The Knowledge Base contains solutions to many common problems!
How to fix "Doesn't have a default value" and "Incorrect string value: xxx for column 'post_text' " errors.
How to do a clean re-install of the latest phpBB3 version.
Problems with permissions? Read phpBB3 Permissions

phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Re: Language File common.php coundn't be opened ?

Post by phpaaa » Sun Jan 04, 2009 6:06 am

they're bb3 language pack ...

my phpbb3 is version 3.0.4, would that be a problem ?

i also found that the error message say "Language file ./language/chinese/chinese/common.php couldn't be opened." ... the file common.php should be at ./language/chinese/common.php not "chinese/chinese/"

isn't it the MODs i installed (Anti-Box, last post topic title and rollover text MOD) cause this error ?

phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Re: Language File common.php coundn't be opened ?

Post by phpaaa » Mon Jan 05, 2009 10:21 am

? ? ? nobody help me ?

User avatar
ric323
Former Team Member
Posts: 22909
Joined: Tue Feb 06, 2007 12:33 am
Location: Melbourne, Australia
Name: Ric
Contact:

Re: Language File common.php coundn't be opened ?

Post by ric323 » Mon Jan 05, 2009 12:22 pm

Where exactly did you download the language pack from?
What was the name of each of the ZIP files?
The Knowledge Base contains solutions to many common problems!
How to fix "Doesn't have a default value" and "Incorrect string value: xxx for column 'post_text' " errors.
How to do a clean re-install of the latest phpBB3 version.
Problems with permissions? Read phpBB3 Permissions

User avatar
Brf
Support Team Member
Support Team Member
Posts: 51875
Joined: Tue May 10, 2005 7:47 pm
Location: {postrow.POSTER_FROM}
Contact:

Re: Language File common.php coundn't be opened ?

Post by Brf » Mon Jan 05, 2009 12:44 pm

It would only act like that if "chinese/chinese" were in the iso-code for that language.
It should say simply "chinese" or "cx-cx" or something else without a slash.

phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Re: Language File common.php coundn't be opened ?

Post by phpaaa » Tue Jan 06, 2009 2:04 am

ric323 wrote:Where exactly did you download the language pack from?
What was the name of each of the ZIP files?
i downloaded three files (chinese, simplified chinese, japanese) "lang_zh_cmn_hant.zip", "lang_zh_cmn_hans.zip"and "lang_ja.tar.gz" from this website ~~> http://www.phpbb.com/languages/

after i copied the unziped files to the relevant folder, i just rename the folders to be chinese, simplified chinese and japanese ... i don't think it would be a problem .

User avatar
Lumpy Burgertushie
Registered User
Posts: 66849
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Language File common.php coundn't be opened ?

Post by Lumpy Burgertushie » Tue Jan 06, 2009 2:26 am

you can't go renaming folders to whatever you want. put them back the way they were and see if that helps.

robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

If a tree falls in the forest and nobody is there, does it make a sound?

phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Re: Language File common.php coundn't be opened ?

Post by phpaaa » Tue Jan 06, 2009 12:29 pm

it's the same, the error now became "Language file ./language/zh_cmn_hant/zh_cmn_hant/common.php couldn't be opened." :cry:

User avatar
Lumpy Burgertushie
Registered User
Posts: 66849
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Language File common.php coundn't be opened ?

Post by Lumpy Burgertushie » Tue Jan 06, 2009 6:06 pm

phpaaa wrote:it's the same, the error now became "Language file ./language/zh_cmn_hant/zh_cmn_hant/common.php couldn't be opened." :cry:
you have a folder inside of a folder, it should be like this:
language/zh_cmn_hant/common.php

robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

If a tree falls in the forest and nobody is there, does it make a sound?

phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Re: Language File common.php coundn't be opened ?

Post by phpaaa » Wed Jan 07, 2009 2:55 am

you have a folder inside of a folder, it should be like this:
language/zh_cmn_hant/common.php
robert
yes i noticed this problem. that's why i asked whether the MOD i installed created this problem. I've installed Anti-Bot question, rollover-text,and last post topic title MOD.

i checked my folder, under folder "forumroot/langage" there are sub-folder "en" and "zh_cmn_hant" ... go futher one layer, under "zh_cmn_hant" there are folders "acp", "docs", "email", "mods". It's just the SAME as the "en" (English) part.

I guess i might solve this problem by creating a new folder "zh_cmn_hant" and put the current "zh_cmn_hant" folder and its files inside this folder. But it's not a formal way and might cause another problem so i don't do this ...

User avatar
Lumpy Burgertushie
Registered User
Posts: 66849
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Language File common.php coundn't be opened ?

Post by Lumpy Burgertushie » Wed Jan 07, 2009 2:20 pm

does either one of those MODs affect any of the registration files?

like ucp_register.php

robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.2 Styles by PlanetStyles.net

If a tree falls in the forest and nobody is there, does it make a sound?

phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Re: Language File common.php coundn't be opened ?

Post by phpaaa » Sun Jan 11, 2009 3:51 am

I've just checked, the three MOD i installed (AntiBotQuestion, 'Topic Post Text Hover' Version 1.0.0 and NV advanced last topic titles version 1.2.8 ). Only the first one requires me to edit the ucp_register.php file. BUT i had installed the first two MODs in my friend's phpbb3 forum and it's working very well. The difference might be my phpbb is the latest version and was installed by my hosting company. ... still checking what's wrong ... :cry:

Also as what i said in the above "I guess i might solve this problem by creating a new folder "zh_cmn_hant" and put the current "zh_cmn_hant" folder and its files inside this folder. But it's not a formal way and might cause another problem so i don't do this ..." I've done that and i could successfully get the chinese registration page. BUT i don't think it's a solution, cause after registration an error message saying can't find the /language/zh_cmn_hant/welcome message. I neglect this and login, the template, button all are still in English but i could still make a post and reply ...

i checked my current ucp_register.php, i can't find any code that would direct user to lang/user lang /user lang/ ... see ... i pick a part of this file to post here ... or i should check another file ?

Code: Select all

line 61 ~ 79 of the file ucp_register.php 

if (file_exists($phpbb_root_path . 'language/' . $use_lang . '/'))
			{
				if ($change_lang)
				{
					$submit = false;

					// Setting back agreed to let the user view the agreement in his/her language
					$agreed = (empty($_GET['change_lang'])) ? 0 : $agreed;
				}

				$user->lang_name = $lang = $use_lang;
				$user->lang_path = $phpbb_root_path . 'language/' . $lang . '/';
				$user->lang = array();
				$user->add_lang(array('common', 'ucp'));
			}
			else
			{
				$change_lang = '';
				$user_lang = $user->lang_name;
Last edited by stickerboy on Wed Jan 14, 2009 11:40 am, edited 2 times in total.
Reason: Removed un-necessary colour from post + added code tags

User avatar
RMcGirr83
Recognised Extension Developer
Posts: 21034
Joined: Wed Jun 22, 2005 4:33 pm
Location: Your display
Name: Rich McGirr
Contact:

Re: Language File common.php coundn't be opened ?

Post by RMcGirr83 » Wed Jan 14, 2009 3:18 am

Have you compared your current includes/ucp/ucp_register.php file to a fresh download of the same from phpBB 3.0.4? Winmerge is excellent for this...and is also free.
In times of change, learners inherit the earth, while the learned find themselves beautifully equipped to deal with a world that no longer exists - Eric Hoffer
Former Modifications/Extensions Team Member | My extensions
Appreciate the extensions/mods/support then buy me a beer
All requests for support via PM will be ignored

phpaaa
Registered User
Posts: 168
Joined: Sun Dec 17, 2006 11:59 am

Re: Language File common.php coundn't be opened ?

Post by phpaaa » Fri Jan 16, 2009 8:31 am

i just tried to debug my problem by copying the original ucp_register.php and ucp_register.html file (from unedited download version) ... the error message "General Error --> Language file ./language/zh_cmn_hant/zh_cmn_hant/common.php couldn't be opened." still exist. SO it might not related to these files ...

i think the key point is which line in which file that would direct the program to "/zh_cmn_hant/zh_cmn_hant" instead of the "/zh_cmn_hant" folder to get the common.php file ? AND why the default language "en" is working very well ... anybody know the answer?

Locked

Return to “[3.0.x] Support Forum”