NukeXchange Network

          

Nuke Sites Link Directory
Nuke Fixes · NukeForums · NukeZone Hosting · NukeUnited · Nuke Sites · Nuke Skins · NukeLance
Nuke Resources
 :: Home  :: Downloads  :: Your Account  :: Forums  :: Advertise :: 
Login or Register
Main Menu
General
 Main
 AvantGo
 Banner_Clients
 cfaq
 Donations
 Downloads
 Forums
 Members_List
 Private_Messages
 Search
 Stories_Archive
 Submit_News
 Surveys
 Topics
 Web_Links
 Your_Account

Your Account
 Login
 Register
 Lost Pass

Modules
Quick Links
· CMS Focus
· Domain Names
. Game Quest
· Learning Linux
. MateMaker
· NukeFixes
· NukeForums
· NukeLance
· Nuke Sites
· Nuke Skins
· NukeZone Hosting
. SearchDevil
Other Options

Download Resources
· Nuke Downloads
· Add a Link
· New Files
· Top Rated
· Most Popular

Web Site Resources
· Nuke Sites
· Add A Site
· New Sites
· Top Rated
· Most Popular

Support
· NukeZone Hosting
· NukeSkins.com
· NukeForums.com
· phpnuke.org
· NukeFixes.com
Information
NukeForums
·PHPNuke 8 security worries
·PHP-Nuke SQL Injection Vulnerability Fix
·decompressing EN-Book-Nuke.tar.tar
·How to allow spaces/gaps/"-" in allowed usernames
·How to Setup PHPNUKE on win2k
·cannot save changes
·voting?
·Nuke forum picture problem
·How to change smtp port on wampserver and windows
·yet another 301 redirect problem

read more...
Top10 Links
· 1: Nuke Forums
· 2: PHPNukeFiles
· 3: NukeSkins
· 4: Nuke Templates
· 5: EcomJunk
· 6: MDesign
· 7: Windows Installation: PHP
· 8: FLASH-FOR-NUKE
· 9: Dezina
· 10: Global Dream News Sharing Portal!
Site Visitors
User Login:

Nickname:
Password:
Security Code: Security Code
Type Security Code Here:

Members List Membership:
Latest: tones
Today: 1
Yesterday: 2
Overall: 15105

Visitation:
Guests: 452
Members: 0
Total: 452


You are Anonymous user. You can register for free by clicking here
Sponsor Links
Download the Best Archiver in the World
Download the Best Archiver in the World

NukeResources :: View topic - BBtoNuke All Versions - language images selection
NukeResources Forum Index

NukeResources Forum Index -> Bug Reports -> BBtoNuke All Versions - language images selection
Post new topic  Reply to topic    View previous topic :: View next topic 
BBtoNuke All Versions - language images selection
PostPosted: Mon Jun 12, 2006 2:51 am Reply with quote
Guardian
Resource Newbie
Resource Newbie
 
Joined: Nov 07, 2004
Posts: 24




I have been trying to fix this for weeks but the answer escapes me.
Issue:
The default location for additional forum language images (the forum buttons) has the following directory structure;
modules/Forums/templates/YourTemplate/images/lang_xxx
Where 'xxx' is the language name i.e. lang_english or lang_german
This directory holds the forum button images e.g. New Topic, Reply etc.

Steps to reproduce:
Upload any additional language images to the directory above.
Nuke Preferences - language is English
Forum Config language is English
Forum Config - allow users to over ride style is TRUE
Amend your FORUM user profile language to a language other than English

Forum button images will still show in english.

Conclusion:
As changing forum config language default to the 'other' languge resolves the problem, it seems reasonably to assume that in includes/functions.php that the users preference[lang] is always being over ridden to the 'default' language.
Caveat
Where a nuke THEME contains a 'forums' directory (such as DeepBlue) the forum image buttons always use those in lang_english irrespective of any configuration settings.
View user's profile Send private message
PostPosted: Mon Jun 12, 2006 10:44 am Reply with quote
darklord
Resourceful
Resourceful
 
Joined: Feb 25, 2006
Posts: 210




Are u talkin bout the text within the pics?

_________________

for those who STAND shall NEVER fall and those who fall shall rise once more...never give up the end is just another beginning.
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
PostPosted: Mon Jun 12, 2006 11:08 am Reply with quote
Guardian
Resource Newbie
Resource Newbie
 
Joined: Nov 07, 2004
Posts: 24




Well, the text, is part of the button image yes, so there fore if you are using anything other than the default English language, the buttons have the text in the incorrect language as the forum uses the buttons from
modules/Forums/templates/subSilver/images/lang_english
This is assuming subSilver is the default template.

Additional language buttons, such as German for example are added in this path;
modules/Forums/templates/subSilver/images/lang_german/

For some reason, when functions.php checks to determine the users FORUM preference settings for language it fails to take that into consideration.

I have determined that the problem lies with two functions in functions.php these are;
function init_userprefs()
function setup_style()

The problem seems to lie with this line (around line 510 in the latest file)
Code:
$img_lang = ( file_exists(@phpbb_realpath($phpbb_root_path . $current_template_path . '/images/lang_' . $board_config['default_lang'])) ) ? $board_config['default_lang'] : 'english';

As you can see, the path looks for the name of the default language only and does not take into consideration the users language preference setting in their forum profile at all.
View user's profile Send private message
PostPosted: Sun Jun 18, 2006 3:02 am Reply with quote
Evaders99
Resource Master
Resource Master
 
Joined: May 25, 2004
Posts: 1785




Hey Guardian

I see you've been trying to debug this for RavenNuke.

I see in the functions.php that the default_lang variable is being set here
Code:

      if ( !empty($userdata['user_lang']))
      {
         $board_config['default_lang'] = $userdata['user_lang'];
      }


So somewhere the $userdata['user_lang'] variable is being handled properly

_________________
- Star Wars Rebellion Network - Evaders Squadron Coding -

Need help? Nuke Patched Core, Coding Services, Webmaster Services
View user's profile Send private message Visit poster's website AIM Address
PostPosted: Thu Jun 22, 2006 11:08 am Reply with quote
Guardian
Resource Newbie
Resource Newbie
 
Joined: Nov 07, 2004
Posts: 24




Correct.
The problem is that there is no update for the forum language images.
You can change your 'prefered' language in the forum profile - not a problem but there does not seem to be anywhere that the forum images are updated accordingly.
Sorry if I am not explaining myself fully..........
If you got to the main forum page you can see a variety of images (buttons) for example 'New Topic', 'Reply to Topic' etc. These are held within the path
modules/Forums/language/lang_english/
As these buttons have text in them which tells you what they do, they are language specific.
If you change your user prefs to say German, the text links appear (quite correctly) in German but the buttons still use those in the lang_english directory.
We can utilise additional language appropriate buttons thus;
modules/Forums/language/lang_german
where the images are loaded into the lang_german directory
BUT unless you change the 'default' language in the forum config, lets say to German, the buttons will always be used from lang_english.

I think this line is the culprit
Code:
$img_lang = ( file_exists(@phpbb_realpath($phpbb_root_path . $current_template_path . '/images/lang_' . $board_config['default_lang'])) ) ? $board_config['default_lang'] : 'english';

If I am interpreting the code correctly if offers the options of the forum default language images, the forum default language images or english images.
So with that code, the forums will always use a $img_lang with the value of 'english' UNLESS the forum config default is changed to say 'german' irrespective of whatever user preferences are in force.
View user's profile Send private message
PostPosted: Thu Jun 22, 2006 5:42 pm Reply with quote
Evaders99
Resource Master
Resource Master
 
Joined: May 25, 2004
Posts: 1785




Guardian wrote:
So with that code, the forums will always use a $img_lang with the value of 'english' UNLESS the forum config default is changed to say 'german' irrespective of whatever user preferences are in force.


But the user preferences does change $board_config['default_lang'])
Code:

      if ( !empty($userdata['user_lang']))
      {
         $board_config['default_lang'] = $userdata['user_lang'];
      }


For some reason $userdata['user_lang'] is not generated or propagated correctly.

_________________
- Star Wars Rebellion Network - Evaders Squadron Coding -

Need help? Nuke Patched Core, Coding Services, Webmaster Services
View user's profile Send private message Visit poster's website AIM Address
PostPosted: Thu Jun 22, 2006 6:47 pm Reply with quote
Guardian
Resource Newbie
Resource Newbie
 
Joined: Nov 07, 2004
Posts: 24




I have responded to your email.
Try not to think 'language' as in 'text' or 'translation' but in terms of images/ buttons.

Mind you it would have helped if I had posted the correct paths - doh!
For english it should be \modules\Forums\templates\subSilver\images\lang_english\post.gif (for the new post icon) for German language it should be \modules\Forums\templates\subSilver\images\lang_german\post.gif
View user's profile Send private message
PostPosted: Fri Jun 23, 2006 1:32 am Reply with quote
darklord
Resourceful
Resourceful
 
Joined: Feb 25, 2006
Posts: 210




im goin to TRY to help as i know my knowledge is limited.

but this is what i have found
and if it isnt useful then uhh itll help me understand better something

http://www.phpbb.com/kb/article.php?article_id=60

im goin to test a theory out.

_________________

for those who STAND shall NEVER fall and those who fall shall rise once more...never give up the end is just another beginning.
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
PostPosted: Fri Jun 23, 2006 2:01 am Reply with quote
darklord
Resourceful
Resourceful
 
Joined: Feb 25, 2006
Posts: 210




as i have tried to learn and look throughout the code...i see somethin which tickled my fancy...i noticed return at the bottom of this function:

function init_userprefs($userdata)

i also noticed no reference to that function with this function:
function setup_style($style)

now im just curious as to this because i ran my phpEd on it and it claimed that the function init_userprefs($userdata) was ended.

now from what i can tell the function init_userprefs($userdata) defines to call on the correct language from the usersdata
and the function setup_style($style) returns the correct images.

this might be true but as my knowledge is limited its doubtfull..im curious if this is correct...i hope this helps

_________________

for those who STAND shall NEVER fall and those who fall shall rise once more...never give up the end is just another beginning.
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
PostPosted: Thu Jul 06, 2006 6:11 am Reply with quote
Guardian
Resource Newbie
Resource Newbie
 
Joined: Nov 07, 2004
Posts: 24




Not sure why I didn't get a notification email for your post darklord - I'll have to check my spam box.
The useprefs DOES correctly set the textual language based on the user preferences i.e. any text links show as German if you set your profile prefs to 'German'.
The issue seems to be that when the userpref is checked, there is nothing to modify the language specific image directory UNLESS you change the 'default' language to German in the forum config area.

Then there is the added kicker that happens when you pick a nuke 'theme' that has forum files (fisubice/Deepblue ).
I'll get around to looking at this all over again when I've finished QA testing RN.
View user's profile Send private message
PostPosted: Sat Jul 08, 2006 2:11 am Reply with quote
Evaders99
Resource Master
Resource Master
 
Joined: May 25, 2004
Posts: 1785




I guess I don't understand the issue Guardian. But then I'm not running a multilingual site. Things seems to work as intended on my testing Sad

_________________
- Star Wars Rebellion Network - Evaders Squadron Coding -

Need help? Nuke Patched Core, Coding Services, Webmaster Services
View user's profile Send private message Visit poster's website AIM Address
PostPosted: Sun Jul 09, 2006 4:37 am Reply with quote
Guardian
Resource Newbie
Resource Newbie
 
Joined: Nov 07, 2004
Posts: 24




No worries Evaders.
I don't have any multilingual sites either but this thing is just irritating the heck out of me. If I can find your email address I may do a couple of screen shots for you to highlight exactly what I mean but I'll fix this one way or another any way - it is just finding the time.
I'll send you whatever code I change/add for evaluation in any event with a view to getting it included in BBtoNuke.
View user's profile Send private message