[RFC] Override Language via URL

These requests for comments/change have lead to an implemented feature that has been successfully merged into the 3.1/Ascraeus branch. Everything listed in this forum will be available in phpBB 3.1.
Danielx64
Registered User
Posts: 304
Joined: Mon Feb 08, 2010 3:42 am

Re: [RFC] Override Language via URL

Post by Danielx64 » Mon Dec 12, 2011 1:47 am

imkingdavid wrote:
*Daniel wrote:Wouldn't you be better off put it at the botton of the page? Or that too far?
I think header would be better. From my experience, foreign websites that allow easy guest language switching have it in the header.
Good point, I'm used to seeing that at the botton of the page rather at the top. I would be good to see how it turms out.

User avatar
imkingdavid
Registered User
Posts: 1050
Joined: Thu Jul 30, 2009 12:06 pm

Re: [RFC] Override Language via URL

Post by imkingdavid » Mon Dec 12, 2011 2:36 am

*Daniel wrote:
imkingdavid wrote:
*Daniel wrote:Wouldn't you be better off put it at the botton of the page? Or that too far?
I think header would be better. From my experience, foreign websites that allow easy guest language switching have it in the header.
Good point, I'm used to seeing that at the botton of the page rather at the top. I would be good to see how it turms out.
Perhaps we could put it in both locations or provide an ACP option to decide where to put it (top/bottom/both)
I do custom MODs. PM for a quote!
View My: MODs | Portfolio
Please do NOT contact for support via PM or email.
Remember, the enemy's gate is down.

User avatar
naderman
Product Manager
Product Manager
Posts: 1727
Joined: Sun Jan 11, 2004 2:11 am
Location: Karlsruhe, Germany
Contact:

Re: [RFC] Override Language via URL

Post by naderman » Mon Dec 12, 2011 3:07 am

No, an option for something like this is overkill. If we made everything an option in the ACP no user would be able to understand the ACP at all anymore. We have too many options as it is already.

tct
Registered User
Posts: 15
Joined: Wed Aug 25, 2010 10:00 am

Re: [RFC] Override Language via URL

Post by tct » Mon Dec 12, 2011 4:52 am

+1

Danielx64
Registered User
Posts: 304
Joined: Mon Feb 08, 2010 3:42 am

Re: [RFC] Override Language via URL

Post by Danielx64 » Mon Dec 12, 2011 5:31 am

naderman wrote:No, an option for something like this is overkill. If we made everything an option in the ACP no user would be able to understand the ACP at all anymore. We have too many options as it is already.
+1 Why don't we have a look at what other software do, or ask users on phpbb main forum where they want to put it.

User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 1731
Joined: Thu Mar 02, 2006 4:29 pm
Location: Earth
Contact:

Re: [RFC] Override Language via URL

Post by DavidIQ » Mon Dec 12, 2011 11:39 am

The setting or the feature? There really isn't anywhere else to put it besides at the top of the forum. If you mean the setting then the answer would be nowhere. If someone wants to remove the drop down they can modify the style and remove it.

In doing this the querystring parameter needs to be preserved throughout the site or selection stored as a cookie (as was the case in the phpBB2 MOD) to preserve the language selection.
Image

User avatar
imkingdavid
Registered User
Posts: 1050
Joined: Thu Jul 30, 2009 12:06 pm

Re: [RFC] Override Language via URL

Post by imkingdavid » Mon Dec 12, 2011 2:28 pm

Okay, okay, no new setting. :roll: :lol:
DavidIQ wrote:In doing this the querystring parameter needs to be preserved throughout the site or selection stored as a cookie (as was the case in the phpBB2 MOD) to preserve the language selection.
I've done some work on this already and I think the easier way would be with a cookie. Currently with the changes I made append_sid() only sometimes adds the lang= paramter to the query string (some links, not others) and I haven't had a chance to look into why (for instance, the board index link has it but forum/topic links don't, even though they're all going through append_sid).

That being said, cookies would only work for people who have cookies enabled. So like I said before... maybe a new session's table column (session_lang)? That way we don't have to keep worrying about updating the URL.
I do custom MODs. PM for a quote!
View My: MODs | Portfolio
Please do NOT contact for support via PM or email.
Remember, the enemy's gate is down.

User avatar
naderman
Product Manager
Product Manager
Posts: 1727
Joined: Sun Jan 11, 2004 2:11 am
Location: Karlsruhe, Germany
Contact:

Re: [RFC] Override Language via URL

Post by naderman » Tue Dec 13, 2011 3:44 pm

There is already a variable for query parameters like this called $_EXTRA_URL which can be used to browse the site with a different style. It's set up in session.php, but I suppose a cookie might be better since it sticks. I wouldn't save this in the session at all.

User avatar
brunoais
Registered User
Posts: 958
Joined: Fri Dec 18, 2009 3:55 pm

Re: [RFC] Override Language via URL

Post by brunoais » Thu Jan 26, 2012 4:15 pm

I like. I give a +1.

MartinTruckenbrodt
Posts: 171
Joined: Sun Jan 29, 2006 1:00 pm
Location: Germany
Contact:

Re: [RFC] Override Language via URL

Post by MartinTruckenbrodt » Wed Feb 08, 2012 1:54 pm

Hello,
adding browser language detection IMO would be the first step before adding a dropdown box for guests. For registered users there could be a save button or a link to the UCP preferences page added near to the dropdown box.

The last thing would be always to change ANONYMOUS user_lang on changing the board default language. This could be done automatically or at least with an extra checkbox.

IMO with these three things multi language pack support for phpBB3 would be completed.

BTW: There are some Olypmus MODs for these features. So, why not to use and to optimize this code for the core?

Bye Martin
Advanced Block MOD 1.1.1 has been released! - Prevent spam on your phpBB3 board with Stop Forum Spam, BotScout, Akismet, Project Honey Pot and several IP-RBL and Domain-RBL DNS blacklists! - My MODs

Post Reply