TinyPortal

Development => Feedback => Bugs/Errors => Topic started by: agridoc on February 07, 2009, 08:36:58 AM

Title: [bugtracker] Block language display options don't work
Post by: agridoc on February 07, 2009, 08:36:58 AM
The problem ramains in subversion 148.

If block is set to display in english it is displayed in all languages. If another language is selected it's not displayed at all.
Title: Re: [bugtracker] Block language display options don't work
Post by: G6Cad on February 07, 2009, 09:53:55 AM
Tested this with English, Swedish, and German and the blocks change the language between the language options ( only tested through language option in Server Settings and not by user profiles )

If i set the blocks to show swedish, they do even if the forum is set to use English as main language.

www.septaldefects.org   ( need to register to change between languages in the profile )
Title: Re: [bugtracker] Block language display options don't work
Post by: bloc on February 07, 2009, 03:38:19 PM
- Logic was faulty in determining when a language was active or not. Fixed for TP v1.0 beta3.

It seems it wasn't accurate enough :P Now it will show the block if a language is set and true for the user, but if none is set(which makes no sense really, to have no languages set) it will simply assume you like to treat it like a normal block.
Title: Re: [bugtracker] Block language display options don't work
Post by: agridoc on February 07, 2009, 05:02:49 PM
I am not sure if language selection for session should be used. It should also work for guests that might select another language, also a user could temporarily change language.

Multilingual sites have language selection options for users and guests.
Title: Re: [bugtracker] Block language display options don't work
Post by: bloc on February 07, 2009, 06:47:10 PM
The $user_info variable will always contain exactly what the user or guest sees. And that is what TP is checking now. It was using the global $language variable earlier, but that can in fact be different from the session language set.