There is a problem with templates in Firefox

Having trouble installing serendipity?
Post Reply
SADtg
Posts: 4
Joined: Wed Apr 11, 2007 9:37 am
Contact:

There is a problem with templates in Firefox

Post by SADtg »

Hi there!

I've just installed s9y on http://blog.sadtg.ru and there is a problem with appearance in Mozilla Firefox. Templates looks perfectly in IE and Opera, but in FF it looks like there is no template at all. I have no clue where the problem may be...
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: There is a problem with templates in Firefox

Post by garvinhicking »

Hi!

That's strange, your base webpage says it's using "UTF-8" charset, but when I request your CSS stylesheet, it uses win-1251 as the charset. I believe that Firefox might be confused by this. Do you know how this happens?

Which charset have oyu set in the serendipity configuration? UTF-8 or native? You are using russuan language files, I assume?

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
SADtg
Posts: 4
Joined: Wed Apr 11, 2007 9:37 am
Contact:

Re: There is a problem with templates in Firefox

Post by SADtg »

garvinhicking wrote:Hi!

That's strange, your base webpage says it's using "UTF-8" charset, but when I request your CSS stylesheet, it uses win-1251 as the charset. I believe that Firefox might be confused by this. Do you know how this happens?

Which charset have oyu set in the serendipity configuration? UTF-8 or native? You are using russuan language files, I assume?

Regards,
Garvin
Yes, there is a russian language. win-1251 is a default server encoding, and I have no idea why it doesn't reinforced by heading() in index.php. In a serendipity configuration set UTF-8.
I've tried to set native encoding (change it in lang files to win-1251), but problem with ff remains.
SADtg
Posts: 4
Joined: Wed Apr 11, 2007 9:37 am
Contact:

Problem resolved

Post by SADtg »

Thank you for idea, the source of error really was in the css encoding.
Server automatically adds "charset=windows-1251" declaration and FF can't deal with it on UTF-8 page.
Resolution was to replace

Code: Select all

header('Content-type: text/css');
in line 60 of serendipity.css.php file with

Code: Select all

header('Content-type: text/css; charset='. LANG_CHARSET);
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Problem resolved

Post by garvinhicking »

Hi!

Ah, well caught. I didn't know we didn't already add this charset at that place. I just committed your fix!

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply