Top.Mail.Ru
? ?
opus

Imagejc


jc, posts by tag: css - LiveJournal

because I say so


Entries by tag: css

New life into an old system
opus
Imagejc
Not much is new. Random thoughts follow.

Friday, I went into uni at 9:15am cursing and swearing, to help deliver a group presentation arguing against using pirated software in a case study. We'd had a week's notice, no meeting where the whole group turned up and a shambles of a plan. I ended up scribbling all of my notes during the first group's presentation, and speaking for longer than the rest of them combined. Went home shortly after and slept until 5pm.

Today I hooked up a nifty Marantz CD player to the decades-old hi-fi setup in the living room. It works well, apart from some distortion.

TV's going to be interesting over the next few weeks. Big Brother 4 started last week with some fun surprises, but I won't talk about that much in this journal. Angel starts on five on Monday, which I'm looking forward to. five has also been showing the Animatrix shorts (in a world TV exclusive), which I have been religiously taping save for the time last night when I stupidly forgot.

I'm really starting to hanker for Digital TV, if only for the reception. Channels 4 and five are bad enough with the decent indoor aerial, and are hardly watchable in my room. I can't bring myself to order direct from Sky after the horrific experience I had with them at the end of 2001, and I think I'd need planning permission for a dish on the roof. It's all a mess, really.

I'm starting to remember tracks I really should've played on my radio show last month, and I kick myself each time I remember one of the kick-ass tracks I previously forgot. Which brings me to my shiny new Kerrang! magazine subscription: thirteen weeks for the price of two and a half. Bargain.

Been thinking about what to do during the summer. I want a job that I'd enjoy doing, yet I'm too picky for my own damn good. Mum and I made a list of things to buy over the next year, so it'll be fun to see how that pans out. I created a new, less personal journal for use in the event that hell freezes over I finish and release my personal web site. I've discovered a neatish CSS hack that proved helpful in fixing Imageearenwe's positioning tactics, and I'm doing bits and bobs to procrastinate further.

Computer's been up for... eleven days and ten hours since I took that pesky RAM chip out. Must find that receipt.

Enjoy this piecemeal entry: no doubt I'll come back and edit the hell out of it tomorrow.
Tags: , ,

CSS problems fixed
opus
Imagejc
Fantastic. Now that I know I can (in CSS) override elements within elements without needing to specify class names, I've fixed my GLOBAL_HEAD CSS so that the page scrolls faster, and the style doesn't look like crap in browsers that don't support CSS. (In those that don't, you'll see a maroon background, black border and white content area, just as it should be.)

I've managed to cut down my override code by a third, and most of my colour values are back to normal. I'm happy now.

Style customisation
opus
Imagejc
For a free account, there's a hell of a lot you can do to customise a basic style. I'm impressed with the results, as you probably will be, but shattered: I've just been through the ordeal of overriding the style of this journal, Punquin w/sidebar, to the absolute limit. And boy, does it play hell with some of the techniques I used.

Now, in an ideal world all major HTML elements in all LiveJournal styles would have a CSS class or ID associated with it, so you can simply manipulate them to your heart's content in a stylesheet placed in the GLOBAL_HEAD override. Unfortunately, Punquin wasn't designed with this concept in mind, so I had to think of another way to do what I wanted to do.

And then it hit me: maybe I could insert arbitrary code into the colour values of my journal. If instead of white I put white" class="something, it would be stuck in a set of inverted commas as normal and would give me two perfectly formatted attributes as a result.

My initial tests went well, but the way LJ parses the colour value is somewhat erratic. I don't know how it's done - maybe somebody with an understanding of the code could enlighten me? - but in some cases it played merry hell with the HTML.

Punquin decided to be even more weird by behaving differently on the New Entries page from all other pages, and its Friends page is designed so as not to let you override FRIENDS_TALK_LINKS or FRIENDS_TALK_READLINK. So much for that. I managed to work around the different treatment of pages by overriding a couple of style attributes in the CALENDAR_HEAD, FRIENDS_HEAD and DAY_HEAD overrides.

Everything now looks great on any recent browser which handles CSS semi-decently. If your browser doesn't support Cascading Style Sheets, this journal will mostly look like crap. Sorry.

Image