News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Problem rendering my forum in Safari?

Started by Col, June 26, 2007, 01:35:22 PM

Previous topic - Next topic

Col

Hi,

I thought my modified forum template worked fine with Safari until I used the utility at browsrcamp.com. using their utility renders the forum without the forum CSS (although it does render the CSS from the CSS file I added for the menubar). I tried switching the forum template to the SMF default, but the browser utility still renders the forum without the CSS.

Can someone check my forum with Safari so that I know if the problem lies with my forum or browsrcamp.com.

http://www.benzobuddies.org/forum/

Thanks.

Kindred

holy moly...   the site does not render properly in safari, firefox netscape or opera...

basically, it looks like it only renders in IE.

Firfox inspector fails you on:
Error: syntax error
Source file: http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/default/script.js?fin11
Line: 1
Source code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Error: The stylesheet http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/New%20Shoutbox%20template/style.css?fin11 was not loaded because its MIME type, "text/html", is not "text/css".
Source file: http://www.benzobuddies.org/forum/

Error: The stylesheet http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/default/print.css?fin11 was not loaded because its MIME type, "text/html", is not "text/css".
Source file: http://www.benzobuddies.org/forum/

Error: syntax error
Source file: http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/default/sha1.js
Line: 1
Source code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Col

I wonder what I've done. I routinely use IE, but check with the other PC browsers. I must have tweaked something and forget to check with the other browsers. I'll have a look now.

Col

Hi Kindred,

I'm confused. firstly I have no problems displaying my forum in FF1.5; NS; or Opera1.5. I've now upgraded FF and opera to the latest versions (I prefer to use the version that most people have, so always upgrade late), and the forum displays fine. The only errors I find with with Dom Inspector are to do with Grudges Shoutbox, and even if i could recode it, I doubt that it would ever validate. Oh, and yes, (shoutbox code excepted) the HTML and CSS do validate with W3C.

I don't usually use FF Dom Inspector, so maybe there is something I'm missing: how do you generate the above errors with Dom Inspector? Again, when I look, all I find are some red entries connected with the Shoutbox.

The errors you listed seem to indicate a problem with the stylesheet links, but what is the problem?

Thanks.

Col

Hi,

I've just used an online service to look at this, and all the browsers (including IE) rendered a forum with no CSS. I've emptied my browser cache and deleted my cookies. What I've found is that the first time I visit the forum, in whichever browser, the forum CSS is not applied. However, if I refresh the browser or visit another page, all is fine with all the browsers. Anyone have any ideas of what's causing this?

Thanks.

Col

This is the header from my forum. I don't think there is anything unusual in it. I do have an additional CSS file - I removed it and added the CSS to the template CSS file, but it made no difference (apart from when I did it, the CSS I moved was no longer retrieved either). I've returned the CSS to my usual setup.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head>

<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<meta name="description" content="BenzoBuddies.org - Index" />
<meta name="keywords" content="PHP, MySQL, bulletin, board, free, open, source, smf, simple, machines, forum" />
<script language="JavaScript" type="text/javascript" src="http://www.benzobuddies.org/forum/Themes/default/script.js?fin11"></script>
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var smf_theme_url = "http://www.benzobuddies.org/forum/Themes/New Shoutbox template";
var smf_images_url = "http://www.benzobuddies.org/forum/Themes/New Shoutbox template/images";
var smf_scripturl = "http://www.benzobuddies.org/forum/";
var smf_iso_case_folding = false;
var smf_charset = "ISO-8859-1";
// ]]></script>
<title>BenzoBuddies.org - Index</title>
<link rel="stylesheet" type="text/css" href="http://www.benzobuddies.org/forum/Themes/New Shoutbox template/style.css?fin11" />
<link rel="stylesheet" type="text/css" href="/css/menu" />
<link rel="stylesheet" type="text/css" href="http://www.benzobuddies.org/forum/Themes/default/print.css?fin11" media="print" />
<link rel="help" href="http://www.benzobuddies.org/forum/?action=help" target="_blank" />
<link rel="search" href="http://www.benzobuddies.org/forum/?action=search" />
<link rel="contents" href="http://www.benzobuddies.org/forum/" />

<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_header = false;

function shrinkHeader(mode)
{
document.cookie = "upshrink=" + (mode ? 1 : 0);
document.getElementById("upshrink").src = smf_images_url + (mode ? "/upshrink2.gif" : "/upshrink.gif");

document.getElementById("upshrinkHeader").style.display = mode ? "none" : "";
document.getElementById("upshrinkHeader2").style.display = mode ? "none" : "";

current_header = mode;
}
// ]]></script>
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_header_ic = false;

function shrinkHeaderIC(mode)
{
document.cookie = "upshrinkIC=" + (mode ? 1 : 0);
document.getElementById("upshrink_ic").src = smf_images_url + (mode ? "/expand.gif" : "/collapse.gif");

document.getElementById("upshrinkHeaderIC").style.display = mode ? "none" : "";

current_header_ic = mode;
}
// ]]></script>
</head>


Any help would be greatly appreciated.

Col

Quote from: Kindred on June 26, 2007, 02:31:45 PM
holy moly...&nbsp; &nbsp;the site does not render properly in safari, firefox netscape or opera...

basically, it looks like it only renders in IE.

Firfox inspector fails you on:
Error: syntax error
Source file: http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/default/script.js?fin11
Line: 1
Source code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Error: The stylesheet http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/New%20Shoutbox%20template/style.css?fin11 was not loaded because its MIME type, "text/html", is not "text/css".
Source file: http://www.benzobuddies.org/forum/

Error: The stylesheet http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/default/print.css?fin11 was not loaded because its MIME type, "text/html", is not "text/css".
Source file: http://www.benzobuddies.org/forum/

Error: syntax error
Source file: http://www.benzobuddies.org/forum/?PHPSESSID=d8bf6161f969acfeec9043a7a718982d&Themes/default/sha1.js
Line: 1
Source code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">



Hi Kindred,

Can you, or someone, please explain the above errors.

Thanks.

padexx

Hi,

could it be this line in your <head>?:
<link rel="stylesheet" type="text/css" href="/css/menu">

Col

I've been looking around, and the above errors indicate a problem with the MIME type being wrong the server. However, the CSS file I've added is passed correctly to the browsers. Anyway, that would not explain why it is just the first visit. Just in case, I added the following to the forum directory .htaccess file:

AddType text/css .css

This made no difference. The CSS is is also passed correctly on pages outside of the forum.

matera

That is the weirdest thing I have ever seen. The forum was buck-naked imageless butt-ugly in both K-Meleon and IE - until I got the URL of one of the missing images:
http://www.benzobuddies.org/forum/?PHPSESSID=fcd2a9dd271f52e6d1897ae72042c54c&Themes/New%20Shoutbox%20template/images/off.gif

and pasted it into the address bar. Boink - everything worked. Same with both browsers. But that is a frightening URL!  ;)

That shoutbox script makes my cursor shudder too - LOL

Once the page is cached it continues to display properly no matter what.

Col

Hi,

I think that was just a server hickup. The same thing happens if I change the forum to the SMF default template (no shoutbox). I intend to add mods to a test forum and see when it fails.

Col

I've found the cause of this problem: http://www.simplemachines.org/community/index.php?topic=165358.0

If anyone has a solution can they post to the above thread.

Thanks.

H

Col another solution has been posted in the other thread since your last message? Have you tried it? Please post in the thread you've linked to and I'll mark this once as solved :)
-H
Former Support Team Lead
                              I recommend:
Namecheap (domains)
Fastmail (e-mail)
Linode (VPS)
                             

Col

This is not solved!

I removed the micro-mod I linked to earlier in this post. I'll look at the alternative code if post a link. I've just installed a test forum, so I could try the code out.

Advertisement: