Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Ravens PHP Scripts And Web Hosting Forum Index -> Raven's RavenNuke(tm) v2.00.00 - v2.02.00 Distro
Author Message
jimmo
Worker
Worker



Joined: Dec 08, 2005
Posts: 107

PostPosted: Sun May 07, 2006 9:29 am Reply with quote

Hi All!

I am running RavenNuke76_v2.02.00 and have configured the site to only use German. For the most part, everything is in German as it should be. However, the images in the forums are being pulled out of the wrong directory. I have set up a single theme fisubice and the images are getting pulled out of
themes/fisubice/forums/images/lang_english and not lang_german. If I remove the lang_english directory, the images disappear.

I tried simply renaming lang_german to lang_english although that is not really a good solution. However, the size of the images are different between the two languages, so the German images with English templates looks goofy. So the obvious solution to to ensure the language is set correctly. The language in the site profile and the forum profile is german. I am at a loss to see where else I can set the language so it also applies to themes/fisubice.

At this point, I am tempted to simply hardcode the langauge to german "somwhere", but I cannot figure out that "somewhere" would be. Still, that is not my favorite solution.

Any help would be greatly appreaciated.

regards,

jimmo
 
View user's profile Send private message
Susann
Moderator



Joined: Dec 19, 2004
Posts: 3191
Location: Germany:Moderator German NukeSentinel Support

PostPosted: Mon May 08, 2006 7:14 am Reply with quote

Well, I´never used the german button. I downloaded from [ Only registered users can see links on this board! Get registered or login! ] the german package and uploaded the lang-german
to themes/fisubice/forums/images/lang_german
and to
modules/Forums/templates/SubSilver/images/lang_german
If I log in and change my theme for example to NukeNews or SandJourney the german button are there but it seems it doesn´t work for DeepBlue and fisubice because I get there the english button of course button with german title tag.
 
View user's profile Send private message
jimmo







PostPosted: Mon May 08, 2006 9:34 am Reply with quote

Servus, Susann!

Thank you very much for your reply. So it seems that you have the same results that I do in that the language is simply not getting set correctly. Hmmm. Since the people I am doing this for want the fisubice theme, looks like I am going to have either hardcode things, dig a lot further into the code or find a similar theme that works correctly. Hmmmm.........

regards,

jimmo
 
Susann







PostPosted: Mon May 08, 2006 9:43 am Reply with quote

I did only a quick test.Need more time to check this a litte bit more. Sometimes it´only setting related. The strange thing is that this works correctly with DeepBlue in Nuke 6.5 and 2.0.17 with both language buttons. I often change my profile there from German to English and it always worked.
 
jimmo







PostPosted: Mon May 08, 2006 10:37 am Reply with quote

The problem is that it is a for a sports club that has a standard color that is almost exactly the same as fisubice. However, what you have found would seem to be that it is not directly settings related. If you do not change the settings, but simply change the theme and it stops working, then it would seem to be theme related.

Since it is extremely unlikely that the club will ever change the theme and even less likely they will allow more than one theme, it isn't that big an issue to hardcode things. However, for my own sake I would love to figure out what is going on.
 
montego
Site Admin



Joined: Aug 29, 2004
Posts: 9457
Location: Arizona

PostPosted: Tue May 09, 2006 6:02 am Reply with quote

Susann, once you complete your analysis, please enter it into Mantis if you feel we can/should fix this... Thank you.

_________________
Where Do YOU Stand?
HTML Newsletter::ShortLinks::Mailer::Downloads and more... 
View user's profile Send private message Visit poster's website
Susann







PostPosted: Tue May 09, 2006 8:49 am Reply with quote

Of course . Wink
 
fkelly
Former Moderator in Good Standing



Joined: Aug 30, 2005
Posts: 3312
Location: near Albany NY

PostPosted: Thu May 18, 2006 1:32 pm Reply with quote

I have tried looking into this and am at a dead end of sorts. I downloaded the directories that Susann listed and uploaded them to my RN test area. Then I switched language to German and went into the Forums but I don't know where to look for the problem.

The only theme that I have available for Forums is subsilver. In the modules/Forums/templates directory there is only a subsilver "theme". However in each of the /themes/ directories, say /themes/fisubice there is a Forums directory and then a bunch of forums related files under that as well as an images and admin directory. I am almost wondering if these files from Forums on down should be over in the forums/templates directory and the fact that they are in /themes is why I can't see them to install them in Forums.

The link on Mantis to see the problem refers to "mysite.com" so that doesn't work. I looked at the demo site for PHPBB and at first I thought that the fisubice button being highlighted was what you meant by the problem but then I realized that any theme that was chosen was highlighted on the left column.

In the forums.cfg files of both DeepBlue and Fisubice there is code like this:


Code:
$current_template_images = "$current_template_path/images";


$images['icon_quote'] = "$current_template_images/{LANG}/icon_quote.gif";
$images['icon_edit'] = "$current_template_images/{LANG}/icon_edit.gif";
$images['icon_search'] = "$current_template_images/{LANG}/icon_search.gif";
$images['icon_profile'] = "$current_template_images/{LANG}/icon_profile.gif";
$images['icon_pm'] = "$current_template_images/{LANG}/icon_pm.gif";
$images['icon_email'] = "$current_template_images/{LANG}/icon_email.gif";
$images['icon_delpost'] = "$current_template_images/icon_delete.gif";
$images['icon_ip'] = "$current_template_images/{LANG}/icon_ip.gif";
$images['icon_www'] = "$current_template_images/{LANG}/icon_www.gif";
$images['icon_icq'] = "$current_template_images/{LANG}/icon_icq_add.gif";
$images['icon_aim'] = "$current_template_images/{LANG}/icon_aim.gif";
$images['icon_yim'] = "$current_template_images/{LANG}/icon_yim.gif";
$images['icon_msnm'] = "$current_template_images/{LANG}/icon_msnm.gif";
$images['icon_minipost'] = "$current_template_images/icon_minipost.gif";
$images['icon_gotopost'] = "$current_template_images/icon_minipost.gif";
$images['icon_minipost_new'] = "$current_template_images/icon_minipost_new.gif";
$images['icon_latest_reply'] = "$current_template_images/icon_latest_reply.gif";
$images['icon_newest_reply'] = "$current_template_images/icon_newest_reply.gif";

$images['forum'] = "$current_template_images/folder_big.gif";
$images['forum_new'] = "$current_template_images/folder_new_big.gif";
$images['forum_locked'] = "$current_template_images/folder_locked_big.gif";

$images['folder'] = "$current_template_images/folder.gif";
$images['folder_new'] = "$current_template_images/folder_new.gif";
$images['folder_hot'] = "$current_template_images/folder_hot.gif";


and basically there are some images that appear to be available in a given language so they are in a language folder within the /images folder whereas there are other images that are generic (no language version) so they are in the "root" /images folder. I don't know if that could possibly be the source of the problem but since I don't know which image is "wrong" nor am I sure how to get these themes to work for Forums I probably can't be much help unless you help me first.

Whew.

If you want to go look at http://frank.ravenwebhosting.com/index.php I'll leave it in German for the time being and you can tell me if you see anything wrong with the Forums. Everything there is set in fisubice. There's still some diagnostic echoes at the top of the forums page from when I was looking into a cookie issue but you can ignore that.
 
View user's profile Send private message Visit poster's website
Susann







PostPosted: Thu May 18, 2006 4:10 pm Reply with quote

This module isn´t active.Sad

You are right the forums.cfg is that important file.

However, I saw before in you forums only the English button "new topic" and "post reply."
Quote:
Then I switched language to German and went into the Forums but I don't know where to look for the problem".
Do you have the German buttons in your folder and forum ?What happens if you change your language in your profile ? I believe we can not easily compare our websites because of the german translation I´m using, the button and possible the settings and of course the structure I changed this for DeepBlue and renamed the folder forums to something else.
I added just the button.zip into mantis.

I´ll give you my url and the name to log in if you like to check and compare with my site.
 
fkelly







PostPosted: Thu May 18, 2006 6:12 pm Reply with quote

Sorry. I realized that when I deactivated the Forums (hoping that reactivating them would pick up missing theme directories) and switched the language over to German I must not have grasped the language needed to reactivate the Forums module. So I tried to temporarily switch back to English and reactivate it and then managed to get myself banned from my own site. I can clear the .htaccess out with FTP but I don't have an easy means to clean the Sentinel banned ip table. (No phpmyadmin). I can cobble something together tomorrow from Raven's SQL load but it will take a little time.

I realized that I didn't put the German images up in the Forums/templates/fisubice/images/lang_german directory on the first go around so I did that now. I'm still not sure what the directory structure should be. Is Forums supposed to pick up themes from the /themes/themename/forums directory or should the forum theme be over in /modules/Forums/templates directory? If it's the latter then I suppose a lot of people doing the standard install don't have it in the right place.

At any rate that's where I'll end it for tonight. Tomorrow I'll try to get access back to my site and see what we can do about reactivating the forums, first in English and then in German.

Edit/update: cobble worked and I cleared out the banned IP table using part of Raven's SQL. Switched things back to English and reactivated Forums. But I still don't see how to make themes other than subsilver available to the Forums. At least I'm learning a little German out of this.
 
Susann







PostPosted: Fri May 19, 2006 4:17 am Reply with quote

Nice you are back. Smile

Quote:
Is Forums supposed to pick up themes from the /themes/themename/forums directory or should the forum theme be over in /modules/Forums/templates directory?

It works well on websites with both button if the path is:

modules/Forums/templates/subSilver/images/lang_german/post.gif
So I quess you need to create a fisubice theme/style in the forums administration.
It´s possible if you have in the folder modules/forums/templates/fisubice uploaded.

I´m not the theme expert maybe I´m completely wrong with fisubice but I think this could work.
 
fkelly







PostPosted: Fri May 19, 2006 8:07 am Reply with quote

I have both a /forums/templates/subSilver and a /forums/templates/fisubice directory and in both I have the /images/lang_German and /images/lang_English directories. However I cannot create an additional theme for the template in administer styles in Forums administration. When I go to add a style the list comes up empty. I've looked at the admin_styles.php code a little and it appears to get info out of the theme_info.cfg file and for fisubice that file references subSilver internally. I'm sort of wondering if it can't create another theme because it thinks this one is already subSilver.

I'm willing to use the test domain Raven gave me to debug this thing but I can't work on it until I can duplicate it.

Later: I've been looking around a bit while writing this. I'm not sure that's what in the /html/themes directory under /forums in there is really correct for setting up a Forums template. I looked in the PHPBB site for instructions on setting up a template and it says:

Quote:
n all futher instructions you should replace "YourStyle" with your style name. Directory name and all filenames is case sensitive, so "YourStyle" and "yourstyle" are not the same and when following futher instructions you should make sure you have correct filename case everywhere.

Copy contents of directory "templates/subSilver" to "templates/YourStyle".
Rename templates/YourStyle/subSilver.cfg to templates/YourStyle/YourStyle.cfg
Rename templates/YourStyle/subSilver.css to templates/YourStyle/YourStyle.css
Open theme_info.cfg, replace all "subSilver" with "YourStyle". Then do the same to all .tpl files in that directory. You can easily do it with almost any text editor by using command "replace all".

Then upload modified files on your forum. Directory structure should be similar to subSilver, except that instead of "subSilver" there should be "YourStyle".


It doesn't appear to me that the "YourStyle" renaming indicated was ever done in these files. Maybe it was never intended, I don't know.

Did you take your additional forum templates from the RN distribution or did you get them elsewhere? Can anyone else clarify this process of creating Forum templates and styles within Nuke? Within the bbtonuke integration process does the Forums software get changed to pick up additonal themes from the /html/themes/forums directories or do those directories need to be modified and moved over to /modules/forums/templates?
 
jimmo







PostPosted: Fri May 19, 2006 11:04 am Reply with quote

Everything should be straight out of the RN distribution with the exception of the images. If memory serves me right, the German images were not provided and I had to pull them from the SubSilver theme.
 
fkelly







PostPosted: Fri May 19, 2006 11:13 am Reply with quote

So you do a plain RN installation. The forum themes are in /themes/themename/forum and not in /modules/forums/templates/themename. You go into Forum administration and click on add a style and a list of possible templates comes up?

If so, I am really perplexed because that's not the way it is working on my test RN installation at:
[ Only registered users can see links on this board! Get registered or login! ]

It's possible that I messed something up with the installation but obviously if I knew what I would have fixed it by now. The site is just out there for testing RN so feel free to go in and I'd be happy to PM an admin user id to anyone who thinks they can help.

And I did FTP the german images over to the site.
 
Guardian2003
Site Admin



Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam

PostPosted: Fri May 19, 2006 9:21 pm Reply with quote

All this sounds intriguing so I have just modified my fisubice theme so that all references to subSilver are changed to a new 'style' call fisubice which is located in the forums/templates directory - I just copied the subSilver template and did a find/replace for 'subSilver' to the new style 'fisubice' (including file names).
Now going to get those German images etc so I can have a play.
 
View user's profile Send private message Send e-mail
Guardian2003







PostPosted: Fri May 19, 2006 9:44 pm Reply with quote

Great, now I'm getting sql errors
Code:


Error in obtaining userdata
DEBUG MODE
SQL Error : 1054 Unknown column 'user_login_tries' in 'field list'

SELECT user_id, username, user_password, user_active, user_level, user_login_tries, user_last_login_try FROM nuke_users WHERE username = 'Guardian2003'

Line : 69
File : login.php
So I'll need to look into that first.
Edit: This issue moved to Mantis (0000221)
 
jimmo







PostPosted: Sat May 20, 2006 1:50 am Reply with quote

Hmmm. Apparently there was a misunderstanding on my part. I assumed that the theme was taken over directly from RN and that I did not need to do any configuration within the Forum itself. On the other hand, I know that phpBB was not written specifically for Nuke, but was ported to work with it and thus the integration is not 100% as with other modules.
 
fkelly







PostPosted: Sat May 20, 2006 6:59 am Reply with quote

I found a modified copy of the theme on [ Only registered users can see links on this board! Get registered or login! ] It has the changes from subsilver to fisubice in it already. I don't have time to experiment today (or if I can make some time it will be later) but in case anyone is "playing" I wanted to report that. I believe it will have to be put into the /modules/forums/templates directory but that's another experiment too.

Unless there is some other explanation I do believe that what's in the RN distribution is ummmm, let's say "not helpful". But maybe I didn't plumb the depths of some readme file that explains this all.

edit: Oh Guardian .. I wanted to add that the PHPBB site has more detailed instructions on editing a theme. I just quoted enough above to indicate the direction it was heading but, I think it's in the Knowledge base there, there are a couple of pages on instructions. I still think it might be easier to get it from NukedMods where they've already done the work.
 
fkelly







PostPosted: Sat May 20, 2006 11:20 am Reply with quote

This keeps getting deeper and deeper.

Evaders indicated on Mantis that the /themes/themename/forums directory was used in styles administration so that the forum theme could be kept consistent with the Nuke theme.

So, I uploaded the fisubice forum theme that I got from nukedmods to /themes/fisubice/forums. Then I went into Forums admin and add styles and it couldn't find anything. Humm ... well the code from admin_styles.php reads in part:

Code:
         $installable_themes = array();


         if( $dir = @opendir($phpbb_root_path. "templates/") )
         {
            while( $sub_dir = @readdir($dir) )
            {
               if( !is_file(phpbb_realpath($phpbb_root_path . 'templates/' .$sub_dir)) && !is_link(phpbb_realpath($phpbb_root_path . 'templates/' .$sub_dir)) && $sub_dir != "." && $sub_dir != ".." && $sub_dir != "CVS" )
               {
                  if( @file_exists(@phpbb_realpath($phpbb_root_path. "templates/" . $sub_dir . "/theme_info.cfg")) )
                  {
                     include($phpbb_root_path. "templates/" . $sub_dir . "/theme_info.cfg");

                     for($i = 0; $i < count($$sub_dir); $i++)
                     {
                        $working_data = $$sub_dir;

                        $style_name = $working_data[$i]['style_name'];

                                                                $sql = "SELECT themes_id
                                                                        FROM " . THEMES_TABLE . "
                           WHERE style_name = '" . str_replace("\'", "''", $style_name) . "'";
                        if(!$result = $db->sql_query($sql))
                        {
                           message_die(GENERAL_ERROR, "Could not query themes table!", "", __LINE__, __FILE__, $sql);
                        }


So I don't see where it is making any reference to the selected theme directory from Nuke. I confirmed this by then uploading to the /modules/forums/templates directory. Now when I went to add a style it finally picked up fisubice and added it. Oh good I said.

Then I went into forums configuration to set the default theme to fisubice. I got the error message that's been reported elsewhere:

Quote:
phpBB : Critical Error

Could not open fisubice template config file

DEBUG MODE

Line : 442
File : functions.php


Now looking at that code we see:

Code:
$current_template_path = $template_path . $template_name;

                $ThemeSel = get_theme();
                if (file_exists("themes/$ThemeSel/$template_name/index_body.tpl")) {
                    include($template_path . $template_name . '/' . $template_name . '.cfg');
                } else {
      @include($phpbb_root_path . $template_path . $template_name . '/' . $template_name . '.cfg');
                }
      if ( !defined('TEMPLATE_CONFIG') )
      {
         message_die(CRITICAL_ERROR, "Could not open $template_name template config file", '', __LINE__, __FILE__);
      }


This is I think the section of code that Evaders was telling us about. So, functions.php is looking for the fisubice (default theme) index_body.tpl and attempting to include a file called fisubice.cfg. But in the /themes/fisubice/forums directory no such file exists -- the file is called forums.cfg. Besides I want to pick the file up from the /modules/forums directory instead. So I did a hack and renamed the file in /themes/fisubice/forums/ to index_body_renamed.tpl. Then I went over to /modules/forums/templates/fisubice and renamed forums.cfg to fisubice.cfg and also renamed while I was at it forums.css to fisubice.css.

Still there? So now I thought I could finally use the fisubice theme. But no, of course not. Now upon going into forums configuration and selecting fisubice you get the error message:

Quote:
Template->make_filename(): Error - file ./../templates/fisubice/admin/page_header.tpl does not exist


Oh dear. Now comparing the directory structures of fisubice versus subSilver you find that subsilver has a whole bunch of files including page_header.tpl in its /modules/forums/templates/subSilver/admin directory and there are only two files in the /modules/forums/templates/fisubice/admin directory which don't include a page_header.tpl. This is also true in the /themes/fisubice/forums/admin directory. And looking at what I got from Nukedmods that's true also.

So what's a body to do? I got into this cause I was asked to look at the language problem that started this thread. Obviously someone out there has working fisubice themes (and deepblue) that work for Forums. But I just don't see how or where they came from. I can't believe that the themes distributed with RN will work as is and the Nukedmod theme is incomplete too. So where did the working fisubice theme for forums come from. If someone can provide this I'll keep looking at the language problem and code but I'm out of my depth (and I just don't have the time anyway) trying to resolve the larger "make the Nuke themes work in Forums" issue.

And finally, if I'm right then maybe the /themes/themename/forums directories should be removed from the RN distribution until these issues are resolved?
 
fkelly







PostPosted: Sat May 20, 2006 2:24 pm Reply with quote

Well Guardian has kindly sent me the files he edited and now I can get the fisubice theme to work in Forums. The missing files were in the admin directory under /modules/forums/templates/fisubice. However, due to the nature of the edits, just replacing subSilver with fisubice everywhere, I believe you just wind up with a clone of subSilver going under the name of fisubice.

To deal with part of this I deleted the fisubice css file (which I first compared with the subSilver css file and it was identical) and replaced it with the forums.css file from the RN distribution in the fisubice directory. Really this file should have been named fisubice.css in the first place. So now I have something that looks like fisubice on my test web page in forums. I'm not at all confident that this is really "correct" though.

I looked at some older Nuke distributions and the only other theme that seems to have a Forum counterpart is DeepBlue.

Now at least I have some missing buttons on my forums (the link at the top of the left "frame" above modules for instance).
 
Susann







PostPosted: Sat May 20, 2006 7:40 pm Reply with quote

Interesting describtion what you did with the different files.
Quote:
So now I have something that looks like fisubice

We can change our files Smile
I have exactly that design I did an export that worked after I changed the folder to chmod 777 and renamed theme_info.cfg but the pictures and the most of the text is gone in the administration and the forum.
So something is still wrong. Rolling Eyes
The urls for the reply button etc. are correct when I change my profile from English to German.
 
Guardian2003







PostPosted: Sat May 20, 2006 9:57 pm Reply with quote

Susann, you said the only themes you cannot see the buttons are DeepBlue and fisubice?
If that is the case, then perhaps that gives us a clue because they are the only two themes that have forum files?
 
Guardian2003







PostPosted: Sat May 20, 2006 10:09 pm Reply with quote

Excellent progress.
I now have full German text and and images working on the NukeNews theme.
Now to investigate fisubice.
 
Guardian2003







PostPosted: Sat May 20, 2006 10:10 pm Reply with quote

HA!
Now working with fisubice
 
Guardian2003







PostPosted: Sat May 20, 2006 10:16 pm Reply with quote

Now I can have the main site theme as fisubice, a choice of either fisubice or subSilver for my forum theme and multiple languages too - interesting.
 
Display posts from previous:       
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Ravens PHP Scripts And Web Hosting Forum Index -> Raven's RavenNuke(tm) v2.00.00 - v2.02.00 Distro

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©