ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

Main Area and Open Discussion > General Software Discussion

CSS File Content "Vanishes" on Ubuntu Machine

(1/3) > >>

raybeere:
I do know this isn't a bug or a problem with Ubuntu as such, but I couldn't think of a short subject that encapsulated my problem any better. And I'm probably missing something obvious, but I have tried to figure this out myself.

To set up the background, I have a set of HTML files which use a custom CSS file. These files are not online, they are for my own use, on my own machines or a USB stick. They contain most of the writing I've done (and will contain the rest when I get the time to add the rest of the files). On Windows XP, under Firefox, they work fine. (The last I checked, the formatting was broken in Opera, but that's presumably because each browser implements the HTML codes differently.) On my PortableApps USB sticks, they work fine. So the relative paths seem to be correct.

Now, I've also copied exactly the same files over to a ThinkPad running Ubuntu. And, although the HTML is there, and the links work, the CSS has no effect at all, in any browser. So I did what I could to track down what was going wrong. I installed Firebug, and it shows the the line calling the CSS file is working - but the CSS file appears totally empty in Firebug as if it contains no style info at all. So I assumed I might have saved it in a text format Linux doesn't like, so I opened up the file in a text editor in Ubuntu, then resaved it. The problem persists... At this point, I'm going crazy.

As I said, I'm probably missing the blatantly obvious. But if any of you can guess what is giving me so much trouble here, with what is meant to be a simple, universal set of files, I'd appreciate some advice. Specifically, if at all possible, I want to be able to use these files on a CD or a USB stick in any OS, without having to tweak them for each one. The fact they don't work perfectly in every browser isn't such a big issue, since Firefox is common enough for my purposes. But these are supposed to be an emergency backup set of all my manuscripts, and the fact I can't make them work as intended is driving me insane.

f0dder:
So, you can view the CSS contents fine with a text editor, it's just when loading through a browser that it doesn't work? Can you load the CSS in the browser with a file:// url?

raybeere:
So, you can view the CSS contents fine with a text editor, it's just when loading through a browser that it doesn't work? Can you load the CSS in the browser with a file:// url?
-f0dder (November 06, 2012, 02:25 PM)
--- End quote ---

I'll have to give that a try. I'm logged into my Windows machine right now, but when I get a chance to fire up the Ubuntu machine, I'll see what happens and post the result here. (What is "supposed" to happen, since I've never tried loading a CSS file that way. Does it just display as text?)

40hz:
Linux is case sensitive when it comes to text. Are you being careful about capitalization?

Consider the following:

<link rel="stylesheet" media="screen" type="text/css" href="styles/my.css" />

The file my.css is not the same file as My.css or MY.CSS as far as Linux is concerned.
 8)

raybeere:
Linux is case sensitive when it comes to text. Are you being careful about capitalization?

Consider the following:

<link rel="stylesheet" media="screen" type="text/css" href="styles/my.css" />

The file my.css is not the same file as My.css or MY.CSS as far as Linux is concerned.
 8)
-40hz (November 06, 2012, 04:35 PM)
--- End quote ---

OK, I understand that - but Firebug made it clear that it considered the file was there, it just showed up as blank. So I don't think that's the problem, unless I'm misunderstanding something you're saying. Which is possible, considering the week I've had...

Navigation

[0] Message Index

[#] Next page

Go to full version