LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 09-16-2005, 10:04 AM   #1
rblampain
Member
 
Registered: Aug 2004
Location: Western Australia
Distribution: Debian 7
Posts: 833

Rep: Reputation: 35
what browser for apache css rendering?


Basically the question is: what would be the best browser to use to obtain css rendering through apache?

I've found it impossible to get CSS to render with my FC2's Mozilla when the code is going through Apache (I'm testing a site on a single machine). The same CSS code renders properly when tried outside of Apache. It seems this may be a known problem.

What I want to do is to find out if it would render properly when using IE since the majority of users use IE but I don't have a windows machine with Apache installed. I assume that if I could find a Linux browser that would render the pages then it should also work with IE. I've tried Opera and it doesn't work, I'd like to try Konqueror but my FC2 distro refuses to start it.

Has anyone had success in this area with another distro? Or a particular browser?

Thank you for your help.
 
Old 09-17-2005, 06:34 AM   #2
rjlee
Senior Member
 
Registered: Jul 2004
Distribution: Ubuntu 7.04
Posts: 1,990

Rep: Reputation: 67
Cross-Site Scripting or Cascading Style Sheets?

Cross-Site scripting is handled on the server side, and the web server (Apache) sends HTML pages to the browser. If these pages are broken then they won't display. Save these pages as raw HTML files and upload them to http://validator.w3.org/ to check them. If they validate, then they should render on any standards-complient browser; if not then they may not render on any.

The only way to test if code will render on IE is to try and render it on IE. There are many bugs in IE's handling of HTML that Microsoft refuse to fix on the grounds that companies exist who rely on this broken behaviour.

Style-sheets contain rules for rendering other data, like HTML. So you can't render them. Rendering is handled entirely by the web browser; Apache just serves CSS files to the browser.

IE is a very common web browser with many known bugs in rendering style-sheets. For the most common instance, it treats the “width” attribute as the element width including borders, margin and padding, rather than the standard which excludes borders, margin and padding.

First of all, check that your CSS code is valid. Go to http://jigsaw.w3.org/css-validator/ and upload your CSS style-sheet. This will tell you if there are any problems with it. If your stylesheet has problems then you'll be lucky to find any browser that will render it.
 
Old 09-18-2005, 08:46 AM   #3
rblampain
Member
 
Registered: Aug 2004
Location: Western Australia
Distribution: Debian 7
Posts: 833

Original Poster
Rep: Reputation: 35
I've followed your advices and checked these HTML and CSS files with the validators. Some errors were found and corrected, only some warnings now remain in the CSS file but the end result is exactly the same.
The same HTML pages (with different content) and the same CSS file have been working without problem for over a year, they do work when they are not accessed through Apache, when they are accessed through Apache,
(<form ......action="http://192.168.1.13/cgi-bin/script>) as a returned document, the CSS link seems to be completely ignored but the rest renders normally.

What does not work is rather basic tags:
<body class='pluie'><table class='tabl01'> in HTML and the corresponding CSS rules are:
.tabl01 {
border : none;
margin-left : 12px;
margin-right : 12px;
text-align : left;
}

.pluie {
background-image: url("/var/www/html/i1/anipluie.gif");
background-attachment : fixed;
}

What do you think I should be looking for?

Last edited by rblampain; 09-18-2005 at 08:49 AM.
 
Old 09-18-2005, 08:55 AM   #4
rblampain
Member
 
Registered: Aug 2004
Location: Western Australia
Distribution: Debian 7
Posts: 833

Original Poster
Rep: Reputation: 35
I've forgotten to mention that these HTML and CSS files were tested on IE about a year ago (I had a Windows XP machine at the time)
 
Old 09-18-2005, 10:41 AM   #5
rblampain
Member
 
Registered: Aug 2004
Location: Western Australia
Distribution: Debian 7
Posts: 833

Original Poster
Rep: Reputation: 35
You were perfectly correct.
I've found mistakes that I reintroduced after following your suggestions, after correcting these, the scripts can now access the CSS file. It seems I'm only left with one problem now, that is the CSS file cannot have a path (for an image) that's suitable for both types of pages, those accessible through the server (Apache) which are relative to the "document root" and those accessible outside of the server. I've given the full path in the CSS file.

All my efforts had one purpose and that is to have only one file (CSS) to edit.
That would be great if somebody had a suggestion about the path.
Thank you very much for the valuable help you've provided.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache not rendering PHP ToothlessRebel Linux - Software 0 11-09-2005 05:23 PM
my web browser "mozilla fire fox" isn't rendering the page, rather opening the page amolgupta Linux - Software 2 07-26-2005 12:41 AM
Add CSS to Apache Autoindexes? dbc001 Linux - Networking 0 12-11-2004 12:38 PM
apache browser information problem kothandaraman Linux - Software 1 12-04-2003 11:29 PM
Apache 2 with Tomcat 4 URL Problem In Browser adcworks Linux - General 1 08-16-2002 12:09 PM


All times are GMT -5. The time now is 03:25 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration