[FIXED] Can't set language in 1.0.9

User avatar
Mohammed
Joomla! Ace
Joomla! Ace
Posts: 1313
Joined: Thu Oct 27, 2005 11:20 pm
Location: Cairo , Egypt
Contact:

[FIXED] Can't set language in 1.0.9

Post by Mohammed » Mon Jun 05, 2006 9:18 pm

Hello there ,

First off , thank you for bringing Joomla 1.0.9 out to light  :) . I was preparing Arabic language file for Joomla 1.0.9 UI , running on my local server with php 5 . After a installing my language pack I was going to set Arabic as default but I encountered this error .




Warning: xml_parser_create() [function.xml-parser-create]: unsupported source encoding "windows-1256" in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1728

Warning: xml_set_object(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1735

Warning: xml_set_element_handler(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1736

Warning: xml_set_character_data_handler(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1737

Warning: xml_set_default_handler(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1738

Warning: xml_parser_set_option(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1739

Warning: xml_parser_set_option(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1742

Warning: xml_parse(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1754

Warning: xml_get_error_code(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1756

Warning: xml_parser_free(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1759

Warning: xml_parser_create() [function.xml-parser-create]: unsupported source encoding "windows-1256" in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1728

Warning: xml_set_object(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1735

Warning: xml_set_element_handler(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1736

Warning: xml_set_character_data_handler(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1737

Warning: xml_set_default_handler(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1738

Warning: xml_parser_set_option(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1739

Warning: xml_parser_set_option(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1742

Warning: xml_parse(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1754

Warning: xml_get_error_code(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1756

Warning: xml_parser_free(): supplied argument is not a valid XML Parser resource in C:\Program Files\xampp\htdocs\joomla\includes\domit\xml_domit_lite_parser.php on line 1759



I reverted to Joomla 1.0.8 and it worked fine ( on php 5 ) , same was well after switching to php 4 .

windows-1256 = is the correct encoding for Arabic language

I can't figure out what's wrong with my configuration .  :-\

Regards,
Mohammed
Last edited by stingrey on Wed Jun 21, 2006 4:43 pm, edited 1 time in total.
"Joomla! is science made clear."
Mohammed Sh. Abbas  -- Joomla! Fan !!

User avatar
stingrey
Joomla! Hero
Joomla! Hero
Posts: 2756
Joined: Mon Aug 15, 2005 4:36 pm
Location: Marikina, Metro Manila, Philippines
Contact:

Re: Can't set language in 1.0.9

Post by stingrey » Mon Jun 05, 2006 9:24 pm

What version of PHP 5 are you using?

Did you see the same problem with PHP 4?
Rey Gigataras
http://www.wizmediateam.com <-- great team of talented Web Designers and Programmers!
http://about.me/reygigataras <-- About Me :)
Partner, Business Development & Project Manager, Event Manager, Sports Coach :D

User avatar
Mohammed
Joomla! Ace
Joomla! Ace
Posts: 1313
Joined: Thu Oct 27, 2005 11:20 pm
Location: Cairo , Egypt
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by Mohammed » Mon Jun 05, 2006 9:29 pm

stingrey wrote: What version of PHP 5 are you using?

Did you see the same problem with PHP 4?
It's ver 5.1.1

No , it's fixed after switching to 4 !

Regards,
Mohammed
"Joomla! is science made clear."
Mohammed Sh. Abbas  -- Joomla! Fan !!

User avatar
toubkal
Joomla! Hero
Joomla! Hero
Posts: 2860
Joined: Thu Aug 18, 2005 4:35 pm
Location: Cheshire, England
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by toubkal » Mon Jun 05, 2006 9:36 pm

I have no experience with using non english language packs but I was able to reproduce the reported error

I installed the arabic language pack from the forge on a server with
PHP 5.1.4
database 4.1.18

I also got the same error
Do you want the answer to be as vague as your question?

User avatar
toubkal
Joomla! Hero
Joomla! Hero
Posts: 2860
Joined: Thu Aug 18, 2005 4:35 pm
Location: Cheshire, England
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by toubkal » Mon Jun 05, 2006 9:42 pm

The front end site appears to be correct, with various joomla texts appearing in arabic

some of the admin screens do not show the error but many do
Do you want the answer to be as vague as your question?

User avatar
Mohammed
Joomla! Ace
Joomla! Ace
Posts: 1313
Joined: Thu Oct 27, 2005 11:20 pm
Location: Cairo , Egypt
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by Mohammed » Mon Jun 05, 2006 10:05 pm

Thanks toubkal for testing .

well , here's the Arabic languege file for 1.0.9 if it counts .

Regards,
Mohammed
You do not have the required permissions to view the files attached to this post.
"Joomla! is science made clear."
Mohammed Sh. Abbas  -- Joomla! Fan !!

User avatar
toubkal
Joomla! Hero
Joomla! Hero
Posts: 2860
Joined: Thu Aug 18, 2005 4:35 pm
Location: Cheshire, England
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by toubkal » Mon Jun 05, 2006 10:33 pm

I have overwritten with those files and have the same errors still.

I can also confirm that reverting to PHP 4.4.2 cures the problem.
Do you want the answer to be as vague as your question?

User avatar
toubkal
Joomla! Hero
Joomla! Hero
Posts: 2860
Joined: Thu Aug 18, 2005 4:35 pm
Location: Cheshire, England
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by toubkal » Mon Jun 05, 2006 10:52 pm

just looked at the file
includes\domit\xml_domit_lite_parser.php

line 1721

Code: Select all

		//create instance of expat parser (should be included in php distro)
		if (version_compare(phpversion(), '5.0', '<=')) {
			$parser = xml_parser_create('');
		} else {
			// special handling for encoding support
			if (defined( '_ISO' )) {
				$iso = explode( '=', _ISO );
				$parser = xml_parser_create($iso[1]);
			} else {
				$parser = xml_parser_create();
			}
		}
I looked on my admin panel PHP info and there is no XML EXPAT parser listed when in PHP 5  mode ( which is only for testing on my host server  and may not have full extensions available ) It is there in my PHP 4 info

Is this possibly the issue. I am not familiar enough with that code to know if it only needs the expat parser for versions before 5.0 or not.

Do you have the expat parser listed in you PHP 5 info Mohammed ?

EDIT for clarity: I meant no Expat parser listed in the PHP info
Last edited by toubkal on Mon Jun 05, 2006 11:09 pm, edited 1 time in total.
Do you want the answer to be as vague as your question?

User avatar
Mohammed
Joomla! Ace
Joomla! Ace
Posts: 1313
Joined: Thu Oct 27, 2005 11:20 pm
Location: Cairo , Egypt
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by Mohammed » Mon Jun 05, 2006 11:36 pm

I looked into php info from Admin Panel and couldn't find Expat parser in neither php 5 nor 4 .

php 4 still works fine though .
"Joomla! is science made clear."
Mohammed Sh. Abbas  -- Joomla! Fan !!

User avatar
infograf768
Joomla! Master
Joomla! Master
Posts: 19124
Joined: Fri Aug 12, 2005 3:47 pm
Location: **Translation Matters**

Re: [INFO REQD] Can't set language in 1.0.9

Post by infograf768 » Tue Jun 06, 2006 4:51 am

The language file provided above works OK on PHP 5.0.4, MySQL 4.1.15 Standard for the front end when language installed via ftp. Choosing Arabic as default language works OK.

But, when going back to language Manager, I get also all these errors.
Last edited by infograf768 on Tue Jun 06, 2006 4:54 am, edited 1 time in total.
Jean-Marie Simonet / infograf · http://www.info-graf.fr
---------------------------------
ex-Joomla Translation Coordination Team • ex-Joomla! Production Working Group

waysearcher
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Fri Jan 06, 2006 9:28 am
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by waysearcher » Tue Jun 06, 2006 4:04 pm

Mohammed wrote: Hello there ,

First off , thank you for bringing Joomla 1.0.9 out to light  :) . I was preparing Arabic language file for Joomla 1.0.9 UI , running on my local server with php 5 . After a installing my language pack I was going to set Arabic as default but I encountered this error .
Same errors for the Slovak language (iso-8859-2 and windows-1250)  :-\

Steps to replicate:
SET
DEFINE('_ISO','charset=iso-8859-2');
or
DEFINE('_ISO','charset=windows-1250');
IN YOUR LANGUAGE FILE

i see these error messages in:
Template Manager [ Site ] => /administrator/index2.php?option=com_templates ,
Language Manager [ Site ] => /administrator/index2.php?option=com_languages and
Content Item:  Edit  [ Section: firstsection ] - Parameters TAB

my system is:
Database Version:  5.0.20a
PHP Version: 5.1.2
Web Server: Apache
WebServer to PHP interface: apache
Joomla! Version: Joomla! 1.0.9 Stable [ Sunshine ] 05 June 2006 16:00 UTC
Last edited by waysearcher on Tue Jun 06, 2006 9:04 pm, edited 1 time in total.
CreativeSites - CMS Joomla services and webdesign - http://www.creativesites.eu

waysearcher
Joomla! Apprentice
Joomla! Apprentice
Posts: 6
Joined: Fri Jan 06, 2006 9:28 am
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by waysearcher » Wed Jun 07, 2006 3:51 pm

Mohammed wrote: Hello there ,

First off , thank you for bringing Joomla 1.0.9 out to light  :) . I was preparing Arabic language file for Joomla 1.0.9 UI , running on my local server with php 5 . After a installing my language pack I was going to set Arabic as default but I encountered this error .
Anyone from the dev. team who can help with this BUG???
CreativeSites - CMS Joomla services and webdesign - http://www.creativesites.eu

User avatar
infograf768
Joomla! Master
Joomla! Master
Posts: 19124
Joined: Fri Aug 12, 2005 3:47 pm
Location: **Translation Matters**

Re: [INFO REQD] Can't set language in 1.0.9

Post by infograf768 » Wed Jun 07, 2006 3:57 pm

They are working on it.
We'll know ASAP
Jean-Marie Simonet / infograf · http://www.info-graf.fr
---------------------------------
ex-Joomla Translation Coordination Team • ex-Joomla! Production Working Group

User avatar
davidgal
Joomla! Guru
Joomla! Guru
Posts: 963
Joined: Sat Aug 20, 2005 9:19 am
Location: Israel
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by davidgal » Wed Jun 07, 2006 4:51 pm

Hi all,

I think that I have identified the issue. I would like to ask you all to try the patch below and let me know if it tests out ok. Also please try other functions that use xml such as newsfeeds to see if all is working.

Original code at line 1721

Code: Select all

		//create instance of expat parser (should be included in php distro)
		if (version_compare(phpversion(), '5.0', '<=')) {
			$parser = xml_parser_create('');
		} else {
			// special handling for encoding support
			if (defined( '_ISO' )) {
				$iso = explode( '=', _ISO );
				$parser = xml_parser_create($iso[1]);
			} else {
				$parser = xml_parser_create();
			}
		}
Please change it to:

Code: Select all

		//create instance of expat parser (should be included in php distro)
		if (version_compare(phpversion(), '5.0', '<=')) {
			$parser = xml_parser_create('');
		} else {
			$parser = xml_parser_create('iso-8859-1');
		}
This should fix the problem as domit (in most versions) does not support multiple encodings. All Joomla related xml files should only include ansii characters in any case.

There may be an adverse effect on newsfeeds. @infograph - can you please check this out
David Gal

User avatar
infograf768
Joomla! Master
Joomla! Master
Posts: 19124
Joined: Fri Aug 12, 2005 3:47 pm
Location: **Translation Matters**

Re: [INFO REQD] Can't set language in 1.0.9

Post by infograf768 » Wed Jun 07, 2006 5:13 pm

Tested on an ISO site.
Change of language is now OK.
Newsfeeds (at least the usual ones in Latin and utf8) display Ok.

Found out that, if my front-end was in Arabic language [windows-1256], some news feeds would display strangely.
Namely Spanish utf-8 feeds would show some Arabic letters instead of some accented characters
Jean-Marie Simonet / infograf · http://www.info-graf.fr
---------------------------------
ex-Joomla Translation Coordination Team • ex-Joomla! Production Working Group

User avatar
davidgal
Joomla! Guru
Joomla! Guru
Posts: 963
Joined: Sat Aug 20, 2005 9:19 am
Location: Israel
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by davidgal » Wed Jun 07, 2006 5:41 pm

infograf768 wrote: Found out that, if my front-end was in Arabic language [windows-1256], some news feeds would display strangely.
Namely Spanish utf-8 feeds would show some Arabic letters instead of some accented characters
Makes sense - you applied an Arabic codepage to the upper ascii characters. What you ask for is what you get  :)
David Gal

User avatar
Mohammed
Joomla! Ace
Joomla! Ace
Posts: 1313
Joined: Thu Oct 27, 2005 11:20 pm
Location: Cairo , Egypt
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by Mohammed » Wed Jun 07, 2006 7:46 pm

Fine !!

thanks david it worked . hope you get this fixed next release

Regards,
Mohammed
"Joomla! is science made clear."
Mohammed Sh. Abbas  -- Joomla! Fan !!

User avatar
toubkal
Joomla! Hero
Joomla! Hero
Posts: 2860
Joined: Thu Aug 18, 2005 4:35 pm
Location: Cheshire, England
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by toubkal » Thu Jun 08, 2006 9:39 am

The fix worked on my test site ok
frontend and backend both appear to display correctly without the errors.

Whilst arabic language chosen, all the english language newsfeeds shown in the newsfeed component looked fine
Do you want the answer to be as vague as your question?

User avatar
infograf768
Joomla! Master
Joomla! Master
Posts: 19124
Joined: Fri Aug 12, 2005 3:47 pm
Location: **Translation Matters**

Re: [INFO REQD] Can't set language in 1.0.9

Post by infograf768 » Thu Jun 08, 2006 10:12 am

Mohammed wrote: Fine !!

thanks david it worked . hope you get this fixed next release

Regards,
Mohammed
I guess that this is important enough not to wait for a release.
A temporary patched file should be made available to all as Rey did for some issues in 1.0.8
Jean-Marie Simonet / infograf · http://www.info-graf.fr
---------------------------------
ex-Joomla Translation Coordination Team • ex-Joomla! Production Working Group

SaVaTaGe
Joomla! Intern
Joomla! Intern
Posts: 75
Joined: Mon Jan 23, 2006 7:22 pm

Re: [INFO REQD] Can't set language in 1.0.9

Post by SaVaTaGe » Mon Jun 12, 2006 2:55 pm

Still getting same problem after applying the patch given above, but I noticed that in php.net user comments  :-\ :-\
xml_parser_create () on php5 sometimes detects the wrong input format for me -- for example, sometimes when i try to parse data that has been fetched from a databse by my script and that only contains a handful of special ISO-8859-1 characters, it seems to think the input was something else and xml_parse() chokes on things like umlauts.

the only reason i was able to figure out so far would be that -- unlike my data files -- the xml data generated by my script doesn't contain the definition. every data source with that definition seemed just fine; it's kinda odd that it worked *sometimes* without it *shrugs*.
no matter what the reason, using utf8_encode () on the string made it work, and prepending '' worked as well.

this problem shouldn't occur in php4, since there you would specify the input encoding along with the output encoding.
Last edited by SaVaTaGe on Mon Jun 12, 2006 3:19 pm, edited 1 time in total.

User avatar
infograf768
Joomla! Master
Joomla! Master
Posts: 19124
Joined: Fri Aug 12, 2005 3:47 pm
Location: **Translation Matters**

Re: [INFO REQD] Can't set language in 1.0.9

Post by infograf768 » Mon Jun 12, 2006 3:13 pm

Which language do you try to install and which PHP version are you using?
Please attach language file here.
Jean-Marie Simonet / infograf · http://www.info-graf.fr
---------------------------------
ex-Joomla Translation Coordination Team • ex-Joomla! Production Working Group

SaVaTaGe
Joomla! Intern
Joomla! Intern
Posts: 75
Joined: Mon Jan 23, 2006 7:22 pm

Re: [INFO REQD] Can't set language in 1.0.9

Post by SaVaTaGe » Mon Jun 12, 2006 3:21 pm

Code: Select all

Database Version:   	 4.1.19-standard-log
PHP Version: 	5.1.4
Web Server: 	Apache
WebServer to PHP interface: 	cgi
Joomla! Version: 	Joomla! 1.0.9 Stable [ Sunshine ] 05 June 2006 16:00 UTC
I have been using Turkish language pack which is attacted to this post
You do not have the required permissions to view the files attached to this post.

User avatar
infograf768
Joomla! Master
Joomla! Master
Posts: 19124
Joined: Fri Aug 12, 2005 3:47 pm
Location: **Translation Matters**

Re: [INFO REQD] Can't set language in 1.0.9

Post by infograf768 » Mon Jun 12, 2006 5:31 pm

EXcept for the fact that your Turkish language file is a 1.0.8 file and needs some updating, I have no problem here (after patch) on PHP 5.0.4.
Jean-Marie Simonet / infograf · http://www.info-graf.fr
---------------------------------
ex-Joomla Translation Coordination Team • ex-Joomla! Production Working Group

User avatar
davidgal
Joomla! Guru
Joomla! Guru
Posts: 963
Joined: Sat Aug 20, 2005 9:19 am
Location: Israel
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by davidgal » Mon Jun 12, 2006 7:37 pm

infograf768 wrote: EXcept for the fact that your Turkish language file is a 1.0.8 file and needs some updating, I have no problem here (after patch) on PHP 5.0.4.
To replicate you need to have the Turkish language installed. Then try and install any other language and see what happens. The issue is that without the patch and if the current encoding of the site is not iso-8859-1 or utf-8 there will be a crash.
David Gal

SaVaTaGe
Joomla! Intern
Joomla! Intern
Posts: 75
Joined: Mon Jan 23, 2006 7:22 pm

Re: [INFO REQD] Can't set language in 1.0.9

Post by SaVaTaGe » Mon Jun 12, 2006 8:19 pm

I changed the XML file's encoding to :

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
and reinstall the language pack, it fixed that problem, but now some Turkish characters cannot seem correctly in content, I suppose that this is a collation problem about MySQL right now...

:( :(

User avatar
davidgal
Joomla! Guru
Joomla! Guru
Posts: 963
Joined: Sat Aug 20, 2005 9:19 am
Location: Israel
Contact:

Re: [INFO REQD] Can't set language in 1.0.9

Post by davidgal » Mon Jun 12, 2006 8:49 pm

SaVaTaGe wrote: I changed the XML file's encoding to :

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
and reinstall the language pack, it fixed that problem, but now some Turkish characters cannot seem correctly in content, I suppose that this is a collation problem about MySQL right now...

:( :(
The encoding setting of xml files and MySQL collation have nothing to do with how characters are displayed. Correct display of characters is ONLY due to having correct and consistent encoding of the html page (as set by the _ISO define in the language file). Consistent meaning that it needs to be correct also when entering any data as well as while displaying data.

The xml file encoding in Joomla! 1.0.x should ONLY be ISO-8859-1 as in most php versions this is the ONLY encoding that the parser supports. Besides nothing else is needed as ALL content in xml files in Joomla! 1.0.x should be pure ASCII (no extended ascii characters).

As for Turkish - the encoding to use is ISO-8859-9. This should also be used if mixed English and Turkish texts appear in the site.

Hope this clarifies things a bit :)
David Gal

SaVaTaGe
Joomla! Intern
Joomla! Intern
Posts: 75
Joined: Mon Jan 23, 2006 7:22 pm

Re: [CONFIRMED] Can't set language in 1.0.9

Post by SaVaTaGe » Mon Jun 12, 2006 10:49 pm

Ok,Ok,Ok

1) I changed the XML language pack's XML file's (turkish.xml) encoding to ISO-8859-1 and saved it in ANSI mode in my text editor
2) I changed the XML language encoding to ISO-8859-9 in language file (turkish.php) and saved it in ANSI mode in my text editor

Code: Select all

DEFINE('_ISO','charset=ISO-8859-9');
3) I applied the patch given above
4) Everything seems OK in frontend but we turned the begining in backend, it gives the same errors...

Code: Select all

Warning: xml_parser_create() [function.xml-parser-create]: unsupported source encoding "ISO-8859-9" in /home/avrasya/public_html/joomla/includes/domit/xml_domit_lite_parser.php on line 1728

and goes on
When I looked at backend HTML source from browser, I noticed that it is using published language encoding (ISO-8859-9) even if backend is english...

And I mentioned the comment about xml_parser_create () on php5, it reads the backend encoding in unknown way...

So, problem still goes on....

User avatar
davidgal
Joomla! Guru
Joomla! Guru
Posts: 963
Joined: Sat Aug 20, 2005 9:19 am
Location: Israel
Contact:

Re: [CONFIRMED] Can't set language in 1.0.9

Post by davidgal » Mon Jun 12, 2006 11:00 pm

Take a close look - I stressed that all xml file encodings need to be iso-8859-1 and not iso-8859-9.
I also mentioned in the previous post in this thread, that if you are using the Turkish language pack and php 5 that you will have the crash (errors that you see) unless the patch is applied.

To fix this you need to apply the patch detailed in my first post of this thread.

Hope that this puts you in the right direction
David Gal

SaVaTaGe
Joomla! Intern
Joomla! Intern
Posts: 75
Joined: Mon Jan 23, 2006 7:22 pm

Re: [CONFIRMED] Can't set language in 1.0.9

Post by SaVaTaGe » Mon Jun 12, 2006 11:21 pm

davidgal wrote: Take a close look - I stressed that all xml file encodings need to be iso-8859-1 and not iso-8859-9.
I also mentioned in the previous post in this thread, that if you are using the Turkish language pack and php 5 that you will have the crash (errors that you see) unless the patch is applied.

To fix this you need to apply the patch detailed in my first post of this thread.

Hope that this puts you in the right direction
ok davidgal, everything is same as you told above...

This is the language XML file :

Code: Select all

<?xml version="1.0" encoding="ISO-8859-1"?>
<mosinstall version="1.0.0" type="language">
	<name>Türkçe</name>
	<version>1.0.8</version>
	<creationDate>2006-02-22</creationDate>
	<author>Joomla! Turkiye</author>
	<authorEmail>bilgi@joomlaturkiye.org</authorEmail>
	<files>
		<filename>turkish.php</filename>
	</files>
</mosinstall>
xml_domit_parser.php as given below (patch applied as you can see)

Code: Select all

//Comment In by Savatage
/*create instance of expat parser (should be included in php distro)
		if (version_compare(phpversion(), '5.0', '<=')) {
			if ($this->xmlDoc->isNamespaceAware) {
				$parser = xml_parser_create_ns('');
			}
			else {
		    	$parser = xml_parser_create('');
			}
		}
		else {
			if ($this->xmlDoc->isNamespaceAware) {
				$parser = xml_parser_create_ns();
			}
			else {
		    	$parser = xml_parser_create();
			}
		}*/

		//create instance of expat parser (should be included in php distro)
		if (version_compare(phpversion(), '5.0', '<=')) {
			$parser = xml_parser_create('');
		} else {
			$parser = xml_parser_create('iso-8859-1');
		}

There is only and only one ISO-8859-9 definition in turkish.php file NOT turkish.xml file, this is needed for viewing turkish letters correctly :

turkish.php

Code: Select all

/** templates/*.php */
DEFINE('_ISO','charset=ISO-8859-9');
DEFINE('_DATE_FORMAT','l, F d Y');  //Uses PHP's DATE Command Format - Depreciated
I donot see the difference between you told and I did, but still it doesnot work... :( :(
Last edited by SaVaTaGe on Mon Jun 12, 2006 11:22 pm, edited 1 time in total.

User avatar
infograf768
Joomla! Master
Joomla! Master
Posts: 19124
Joined: Fri Aug 12, 2005 3:47 pm
Location: **Translation Matters**

Re: [CONFIRMED] Can't set language in 1.0.9

Post by infograf768 » Tue Jun 13, 2006 3:58 am

SaVaTaGe wrote:
2) I changed the XML language encoding to ISO-8859-9 in language file (turkish.php) and saved it in ANSI mode in my text editor

Code: Select all

DEFINE('_ISO','charset=ISO-8859-9');

turkish.php file is not an xml file and should be saved with the same encoding as chosen for the ISO, i.e. in your case ISO-8859-9.
Jean-Marie Simonet / infograf · http://www.info-graf.fr
---------------------------------
ex-Joomla Translation Coordination Team • ex-Joomla! Production Working Group


Locked

Return to “Q&T 1.0.x Resolved - Archived”