Add to Technorati Favorites

Monday, 3 September 2007

You're having a laugh?!

Somebody at Adobe deserves a slap upside the head with a large blunt instrument - I'm thinking something the size of a planet here.

All I want to do is create a nice box that pops up over the top of a webpage in flash, and allows you to enter some data into a form in order to get some information back from a database. In Flash 8, the XML coding was so rickety, I ended up giving up - sometimes it would load XML from the server, other times it just forgot. Not to mention that it would load everything fine the second time it went through the script, but not the first. That's sure to look professional.

So I decided to upgrade to Flash 9 (or CS3 as Adobe are calling everything these days) to see if it would sort the problem out. After discovering that they'd pretty much completely re-written actionscript, and that my file would have to be re-programmed from the ground up, I found that the new way of working with XML was not only much better, but it worked! W00t w00t! Finally I could select things in my comboboxes, and have the data load straight from the database into flash (via PHP and XML).

Unfortunately my joy was short-lived, as some pillock at Adobe had obviously decided that nobody would ever want to layer form controls over the top of HTML. Having the wmode setting set to "window", everything works fine, but setting it to "transparent", which is what I need to if everything's going to look nice on top of the HTML doesn't show the comboboxes at all. WTF??? In IE it's fine, but Firefox pretty much just keels over and dies the second you try to do this. I've reported this as a bug to Adobe, but nobody seems to be able to find a workaround for this at the moment. Dammit! Flash would be perfect for doing this if Adobe weren't the equivalent of programming gypsies.

The only mention on the Adobe website to the problem that I can work out is this cryptic message about The plugin version of Flash Player does not fire flash.events.Event.RENDER when wmode is set as transparent. (198515). Well, thanks very much, you really cleared that up for me Adobe. By the way, the link on that page takes you to a broken link page. Very professional to say these guys are supposed to be at the forefront of web design, and their own software has a site-wide link checking feature to make sure they all work.

Incidentally, has anyone noticed the download size for Flash has changed from about 70Mb for Flash 8 (when Macromedia were still making it) and 460Mb now Adobe make it? It took me about 3 hours to install it earlier, and still it's riddled with bugs. And they have the cheek to ask $699 for this?? I've seen less infections on a chinese whore with leprosy, AIDS and Windows '98(which is a well known ailment) all at the same time.

Saturday, 1 September 2007

Would you like me to lapdance for you?


OK, I had to share this with you - this is (hopefully) the laptop that's going to be arriving on my doorstep sometime before we head off to Ibiza. I'm really happy about a couple of the features on this model. No it's not the fact that it's got a spill-proof keyboard (although that'll be useful for DJing with) or it's firewire 800 port (which I'm very happy about, nonetheless) - It's the fact that the promotional pictures for this model show a screen saver that says ASUS: Rock Solid, Heart Warming.

I mean, the rock solid part pretty much speaks for itself, and I'm happy about that, really I am - when I'm playing at a gig, I need my laptop to be my rock, because god knows none of the drunkards falling against my lighting rig are going to do that for me. What I'm really happy about is the fact that this laptop is "Heart Warming". I feel like this laptop has already warmed my heart. Because this laptop is on its way to me, I just want to leap out the door, kiss the first person I come across in the street, and shout things like "Yay fiddlesticks" and play songs that include lots of "Shoo-bob Showaddy-waddys" in. Only the bloody Japanese could have possibly advertised a laptop as "Heart Warming" and got away with it.

Which brings me onto the other feature I'm really looking forward to checking out - the ASUS Splendid Video Intelligence Technology which is built into it, apparently. It's all splendid, all the time. You Mac fanbois can keep licking Steve's arse for all I care, so long as my lappie has Splendid technology, I am good to go.

Friday, 31 August 2007

No man is an island...


Well, it was going to happen sooner or later - I'm finally going back to the island! I really can't wait - I'm getting so homesick right now, and I'm missing everyone out there so much! There's a huge part of me that's so relieved that I have a date to go back home - I arrive back in Ibiza at midnight on the 18th of August. I just want to run round and use exclamation marks at the end of every sentence! Nothing is getting in my way of that small pleasure! Nothing!

Of course, I've just had the normal run-down from my Dad about the whole thing - until now he was forcing me out of the house into a cardboard box on the streets of Leeds. Suddenly he's all "What's wrong with living here?" and "Are you sure you're going to be ok in Ibiza??" - errm. I think I've lived out there long enough already to be able to be ok, thanks Dad. Everybody seems to be acting really surprised about the whole thing, like they expected that I'd got Ibiza out of my system already, and now I'd settle down, get a mortgage and have 24 kids or something. Sorry to disappoint you everyone, but I can't do that right now. England is doing nothing for my happiness right now, and I'm sorry to say, but Ibiza was my home (and will be for as far into the future as I can see right now), and has been since the day I got there.

I'm not entirely sure how things are going to work out on the island just yet - I know it's the off-season, but I've got enough web design work to be getting on with, so hopefully that will keep me going for a little while at least. I hope so anyway, because I've just bought myself a brand spanking new laptop. My old one is falling to pieces, and I really want to be able to mess around on Ableton again, and be able to have more than 2 plugins going at the same time, it's kinda limiting me right now. That and the fact that my laptop's power supply feels like it's going to blow up at any moment, and I've normally got a pretty good feeling about these things.

I actually really like the island off-season. There's no tourists for a start, which means you can pretty much have the beach to yourself. Also, a lot of the locals don't work through the Winter, which means that everyone ends up at each other's houses watching House, and anything else English on the FX network.

Things I'm missing about the island:
  • All the usual suspects (in no particular order) - Jimmy, Krystle, Ben, Donald, Milena, Linda, Janey Pie, Tamara, Lucky, Andy, Havier, and all the rest of them.
  • Never knowing where you're going to be at 6am.
  • Hash
  • Sun rises
  • The beach
  • Staying in to keep cool, not to keep warm
  • Cheesy Spanish Telly
  • Shops that are just a front for selling drugs
  • Walking everywhere
  • Seeing everyone you know even if you just pop out to the shops for a croissant (a 2 minute walk generally ends up taking about half an hour)
  • Pacha (there's so much I miss about this place - the funky room, Subliminal Sessions, Vaugn, the anticipation of getting dropped off in the taxi outside, coming out and finding it's light outside, the walk home, the woman selling chupachups in the toilets...)
  • Bar Sin
I could go on and on and on, but I'm going back there in 2 weeks! Yayayayayayyyyyyy!!!!!

Saturday, 18 August 2007

Jim's enquiry bell please.



I had a bit of a break from work this week because I went to London with Marisa to see one of her favorite bands, Tegan and Sara. We got up at the ungodly hour of 11am, and blinking in the bright light of gloomy countryside england we tried to haul ourselves out of bed. After the usual interrogation from Dad ("Where are you going??" "Why??" "I expect you'll be taking lots of drugs?" - my Dad has a really high opinion of me.) we drove bleary-eyed down to Ilkley Station in the party wagon.

On the train down to London, we experienced the most amazing feat of all that is Woman - a knitting competition between some old biddy that looked like a a man, and this lass who looked like she was about 5, bless her. The old biddy was seriously going for it - I'm not sure what it was she was knitting, but I don't doubt it was some amazing device to counter terrorism against the Western World. In the event of World War III, I have no doubt that we can just get all the old biddies in the country to knit a protective shield for the country out of teflon wool or something. I was so intrigued by her arthritic dexterity that I filmed her for a good few minutes through the gap in the seats. This wasn't even the best part of it, later on she started dispensing old-people wisdom whilst knitting. There was no stopping this girl, she had it all: style, wit, wisdom, needles, some wool, and more facial hair than me.



It seemed really unfair on the little lass, the biddy just seemed to be toying with her, like a cat plays with a mouse, but little knitter was trying her best to keep up. She did well, and in the great knitting train race, eventually finished 2nd. Well done wee knitting type. I hope one day you, too can achieve flowing golden facial hair and infinite wisdom.


After witnessing possibly the greatest head-to-head knitting contest of all time, I decided to eat my chicken curry baguette, taking the cucumber out first, obviously. Then I took some pictures out of the window of blurred things going past. It filled the time in, and my GameBoy wasn't charged, so I was sulking.










Then I had a nap, while Marisa took pictures of herself. One day I'm going to make an album of all the pictures Marisa has taken of herself on my camera.


I woke up to find I was being acosseted by a dodgy old GNER fanboy who wanted me to buy some crisps off him. He didn't have any prawn cocktail crisps, which seemed a little pants, so I settled for some stupidly salty sea salt flavour crisps. Why would anyone every dream up making a "sea salt" flavour? I mean sea water is possibly the most disgusting thing to have in your mouth ever, so designing a whole flavour of crisps around this fact doesn't seem a very good marketing strategy. You might as well call it "Walkers Sewage Sensations". Yum. I tried to surreptitiously take a picture of the mad old bastard, but he was quite wily in his old age, and had anti-photo cloaking technology on his side, possibly knitted for him by his mother.


After that, we just had time to take a few pictures of Marisa modeling an article about the Distillers, who looked like they would all order a foot-long hearty Italian crack sandwich if Subway started selling them.


Finally we arrived in London town, and dived into the underground system, trying to find out how to get to Shepherd's Bush land. Using my powers of cunning, I found that by battering a few Londoners, they willingly gave up the closely guarded secrets of the tube system, and soon we found ourselves on a direct train to the Bush.


We did what any normal person would do when arriving in the Bush for the first time: we looked around in sheer and abject horror at the total ghettoness of it all. People who until now had appeared like nice librarian types suddenly seemed armed and dangerous. I mean I've stayed in some pretty ghetto parts of the world before now, but I think in many respects I'd prefer to take a South African shanty town over Shepherd's Bush any day of the week. At least they smell better, and they have a roof over their head. Oh, and they don't have to put up with a mobile phone accessory shop (shop is such a strong word in this circumstance - most of them were just a cardboard box with a man sat next to it) every other metre on the street.

After our first foray into the art of getting lost in London, we successfully used Google Maps Mobile to locate our position in the sewers, and found our bed for the night, the very lovely Jim's Shed and Breakfast (or it might just as well have been) - notice on the website it says "Welcome to London's finest"... finest what, exactly? Stable? Dungeon? That would be true at least, the real London dungeons have nothing on Jim's Shed and Breakfast. "Jim" actually turned out to be short for Mohammed, who quickly decided he'd never heard of us, even though we'd paid in full by card before our trip. After 20minutes of waiting around, they found our booking, scribbled on a piece of used toilet paper in the "office" (which was a 20x20cm area in front of the fish tank in the kitchen). Something else I just noticed about the Jim's Shed and Breakfast is the location page: "For a list of all local hospitals and where they are in connection to Jim’s Guest House, visit here." - There's a very good chance that you'll be visiting a hospital after staying at Jim's, so this is useful information to have. Everything in Jim's seemed to be downstairs - the reception, our room, even in the bathroom you had to go down 5 steps to get to the toilet. I spose that way if you miss (I mean like really badly miss) it'll still find it's target eventually.

Jim (a.k.a Mohammed) seemed to be a big fan of motivational posters. I hate these things. Jim's favorite was positioned on the stairs leading to the reception - it read something like "Excellence: Excellence is the difference between doing something nearly right and doing something really right." with a picture of an arrow falling onto the bullseye. The only problem with this is that you don't drop arrows onto a dartboard, you throw them. Any big fat darts player wanting to play darts in a big fat darts contest will get laughed off stage by Jim Bowen himself if he tried dropping the dart onto the board. It just doesn't work that way. If I was into motivational posters, this is how they'd look:


The only saving grace of the room that we ended up in was that it had the bounciest bed in the world. The unfortunate downside of this was that even if you slept directly in the middle, you still felt like you were going to fall off. The centre actually felt worst of all because somehow it made you feel like you were going to fall off in four directions at once - even now I'm still wondering how it did this.

After dumping our crap in the room, we ran out (partly out of curiosity, partly due to wierd animal mating noises coming from under the bed) and deep into the Bush.









As you can see, the Bush rates alongside such holiday destination hotspots as Scotland, and Auschwitz. After buying some cockney caps (2 for £10 from any reputable road-side seller called Ali) so that we fit in (disguise is everything in the Bush), we eventually managed to get in touch with Aaron, who was on a mission in Tottenham Court to get well and truly fucked. We hot-footed it over there on the tube, just because we wanted to get out of the Bush (which was beginning to look more and more like they'd filmed parts of Apocalypto there on location). On leaving the Bush, we suddenly found we were really hungry for anything that wasn't nasty kebab. I'll tell you something, if you ever get a craving for nasty kosher meat, you won't go hungry in the Bush. I'll carry on in a seperate blog post, cos this is getting a little long...

Tuesday, 14 August 2007

By the end of my life...

What I really want to be is a walking Swiss Army knife. But a useful one. The problem with Swiss Army Knives is that they have so much potential, but they're never around when you need them, but when you don't need them, they're just everywhere.

Case in point: My horse (well, my hypothetical one, at least) gets something stuck in it's hoof while we're hypothetically out on a hack. A perfect time to whip out my trusty blade, and use the horses hoof picking attachment to heroically dispatch the rogue rock/bit of twig/mine the poor daft mare has stepped on. What actually happens, of course is that while the horse is going crazy-wild with pain, and trampling on every daft old biddy that thinks She can horse whisper it into submission, you realize that you left your 587-function Swiss kit in your other jacket. Bugger. Meanwhile, as She was looking for your packet of fags in your jacket, and going a bit loopy from a nicotine withdrawal, your Sister finds the aforementioned multifunction device and tries smoking the can opener, and dies of blood poisoning because you used the can opener to pick the dirt out from under your toenails last Tuesday. True story. Hypothetically.

What you really need is a Swiss Army knife that will never be parted from your side, with real useful tools. To which end, when the technology becomes available, I want each of my fingers converted to do something other than just holding things.

Here's what I've come up with so far:

  • Right thumb:
    Would make a great bottle opener.
  • Right index finger:
    I'm going to get this finger sharpened, to be used as an offensive weapon, that I can just jab somebody in the heart with if the need arises. Maybe I could have it poison-tipped as well, I haven't decided yet. I'm considering using this pro-actively to kill scallies and smelly old men who hang around Tescos. The way I see it, it's them or me, and with my poison-tipped index finger, chances are, it's them.
  • Right middle finger:
    Screwdriver/egg whisk. It's interchangeable depending on whether I'm making a spice-rack or making a cake.
  • Right ring finger:
    Skeleton key. I always wanted a skeleton key, and if you've got one attached to your hand at all times, you can get into any locked room/car/safety deposit box.
  • Right pinky:
    I'd have extended and straightened so I'd look totally baller while drinking Earl Grey at high-tea. All us English guys drink Earl Grey. It's the law.
  • Left thumb:
    64GB USB Thumb Drive. It detaches, so you can easily steal important documents from unsecured computers no bother.
  • Left index finger:
    Extendable Firewire 2 cable, for interfacing really fast to computers, perfect for one-handed web browsing.
  • Left middle finder:
    I would just have made bigger, for 2 reasons: 1) You can flip people off with style. 2) Girls would love it. Especially if you could hook up some way of converting blood sugar into energy to vibrate it. Yeeeaaahh.
  • Left ring finger:
    Wax crayon. There's never one around when you really need one. Remember those crayons you used to be able to stick all your fingers into different colours and draw crap pictures with? It'd be like that, but attached. It doesn't get better than that.
  • Left pinky:
    Laser spirit level. I'd never actually use it for it's spirit levelling purposes, more for it's blinding purposes (mostly on double-decker buses). In America you could have one of those laser pointer pens, but we're not allowed those in Britain for exactly that reason.
Comments? Suggestions?

Wake Up Your Car...


The website I'm doing for my work at Drive-In is finally starting to come together now, I've just uploaded a test version while the domain is being swapped over, there's still a lot to do, but at least people can get at the information now :) Tell me what you think!

Sunday, 12 August 2007

A DJs weekend from hell

I've definitely had better weekends when it comes to DJing! It all started on Friday night - I'd already picked up both the rigs I needed from Rod's house on Thursday, so after work on Friday, all I had to do was drop off the stuff for Ben at his gig in Burley-in-Wharfedale, then race back to Hollins Hall at Guisley, and set up my own rig there.

However, halfway through setting up, Ben phoned me, to tell me that I'd not given him a microphone. Bugger. I got some background music going, then jumped in the van, raced back to Burley, and dropped the spare I had with me off for Ben, only to find that Ben was nowhere to be found, and that there were a load of Emo teenagers pissing about with the rig! I told them off, then raced back to my own gig.

So yesterday, I went back to Burley to pick up the rig with Alice, and just as we're leaving Burley I notice that the "door open" light is flashing at me on the dashboard. I get out and slam all the doors to make sure they're closed, but everything seems to be fine, so I drive on. Then just as we're going up the hill to go home, the boot suddenly opens, and everything spills out onto the road behind us! The speakers seemed to bounce for about 5 years before finally coming to a stop somewhere in Egypt. Bless her, Alice jumped out of the car while we're still moving, and ran to try and get everything picked up, while I parked the car across the road with the hazard lights on to stop these 2 grumpy old men that had since driven up from getting a 1000W JBL speaker-sized imprint in their bonnet. We got everything loaded back in, but found that the catch on the boot had somehow broken, which was why it had come open in the first place, and it wouldn't shut properly. We drove up the hill as slow as possible, and made it home without any incident. Then when I came to open the boot again, the speakers decided to fall out again, one of them directly on my foot, and then went rolling into Alice's knee. I think they have something against us.

From there, it just got worse - I went to set up at my gig last night (a Scottish woman's 70th birthday), to find that only about 20 people had turned up. Just as I was doing a sound check, the woman who'd booked me came up and said "You do have some waltzes, don't you? Only I think the people Betty's age would like that." Greeeaaat. This is gonna be one fun party. I have no waltzes. None. I pride myself on that fact, and to be honest, until this moment, I've never had cause to have any waltzes.

I spent the entire night playing swing tracks to an empty dancefloor. At one point a grand-daughter of the birthday girl asked me for Rhianna - Umbrella, a track which I hate with a passion. But, I figured that since none of the old biddies were requesting anything, I might as well. The younger people in the room instantly got up to dance, but about a minute into the track a miserable old git who looked like he was probably 600 years old came up and started giving me abuse!
"Don't you think you should be playing songs Betty wants?!"
"Well, I've played all the ones on her list, and nobody danced to them, so I thought I'd play this one because the girls asked me for it, is there anything you'd like to dance to?"
"You should fucking know that, you're the DJ!"
At this, he stormed off, to give me evil looks from the other side of the room for the rest of the night, while I was left to play funeral dirges (Danny Boy was a track they'd requested for the event, I ended up playing it 4 times through the course of the evening - if I'd have had a "NOW that's what I call depressing music!" album, they would have been going mental) for the rest of the night, while one daft old man who looked like he'd taken 15 grammes of Ketamine spazzed out on the dancefloor, and had a heart-attack.

To top it all off, because I'd had to put all the equipment on the back seat, when I got home, I couldn't see to reverse, and ended up backing the van straight into the gatepost, pretty much destroying it, and cracking all the brake-lights. Great.

Making a 3 Column Blog

Blogger is great, we all know that - you can have a blog set up and running within about 2 minutes, and it'll look great just using the templates that they provide you with. If you're happy with the way things look then everyone will live in peace and harmony for ever and ever and ever. However, if there's something you want to change about the template, blogger can be a complete nightmare. Yes, everything is styled in CSS, which makes things a little bit easier, but if you don't know what's going on, you don't have a hope in hell of getting things to look the way that you want.

A couple of people this week have asked me how to make their default 2-column blogger template into a wider 3-column template - sounds pretty easy, but we are gonna have to get our hands dirty with the actual coding of the page to make it happen. Before we begin, a quick note: The blogger templates are set up so that they will be viewable on the smallest possible screen size (640x480) and people will not have to scroll horizontally. By increasing your width with 3 columns, the people using this resolution will have to do a lot of scrolling to see your content. However, looking at my stats for the last month for my blog, not one person was using this screen resolution (out of over 5,000 visitors), so this is a pretty moot point.

First of all, a bit of explanation on how the default blogger templates are set up. In order to get everything laid out on the page where they want it, they use Divs, and style them using CSS. Divs are a way in HTML of positioning a block of content exactly where you want it on the page. They're a little like tables, but instead of having to make sure that one table cell takes up x amount of space in order for another to appear in your desired position, with Divs, you can tell it an exact coordinate. Here's a diagram showing the Divs (and their names) on a default blogger template:


These are pretty self explanatory - the only one that may cause a bit of confusion is the outer-wrapper - this is basically a hold-all for all the other information contained within the page, and gives the divs contained within a reference for positioning. The divs will have different dimensions, depending on what default template you've chosen. This is how we want the template to look:

Here is where things start to get messy. The first thing we need to do is increase the width of the content-wrapper so that it can accommodate another sidebar on the left. The default sidebar is generally around 220 pixels wide, so we'll need to increase by this amount. Go into the Edit Template HTML page for your blog (dashboard>layout, then choose the Edit Template HTML tab at the top of the page). Now you need to find the part in the code that controls this outer-wrapper width - in the minima template this is about 1/3 of the way down the page - you're looking for:

#outer-wrapper {
width: 660px;
margin:0 auto;
padding:10px;
text-align:left;
font: $bodyfont;
}

This controls all the dimensions, margins and positioning for all your content in your blog. Some of the settings may be a little different, depending on your template, so don't be alarmed if this is the case. Change the width value to 780px. This is the maximum size width that people looking at your blog will be able to see without scrolling horizontally at 800x600 resolution (you need to allow 20px for the scrollbar on the right). While you're here, below the code you just edited, you'll see a section named #main-wrapper - change the float option in this section to center instead of left, so that it looks like this:

#main-wrapper {
width: 410px;
float: center;
word-wrap: break-word; /* fix for long text breaking sidebar float in IE */
overflow: hidden; /* fix for long non-text content breaking IE sidebar float */
}

This won't change much when people actually look at your page, but it will help you see things the way they're supposed to be in the layout editor. Now we need to change all the other divs so that they will fit with this new width. We'll deal with the header first, and work down. The header code is actually above the outer-wrapper code. This is what you're looking for:

#header-wrapper {
width:660px;
margin:0 auto 10px;
border:1px solid $bordercolor;
}


Again, change the width to 780px (we want the header to take up the entire width of the page). Same with the footer (further down the code):

#footer {
width:660px;
clear:both;
margin:0 auto;
padding-top:15px;
line-height: 1.6em;
text-transform:uppercase;
letter-spacing:.1em;
text-align: center;
}


Change the width to 780px again. Here's where things start to get interesting. The existing sidebar and the div that will contain the main content, we want to keep around the same size, and just budge them over enough to fit in another sidebar div. We need to copy and paste the existing sidebar-wrapper code to make the new sidebar to the left. Find this near the top of your code:

#sidebar-wrapper {
width: 220px;
float: right;
word-wrap: break-word; /* fix for long text breaking sidebar float in IE */
overflow: hidden; /* fix for long non-text content breaking IE sidebar float */
}


Change the width of this sidebar to 200px, then paste your new sidebar code directly underneath this one (it doesn't really matter where you put it, but it helps to keep all the wrappers together so you can find them easily if you need to. Change the values to something like this:

#sidebar-wrapper2 {
width: 170px;
float: left;
word-wrap: break-word; /* fix for long text breaking sidebar float in IE */
overflow: hidden; /* fix for long non-text content breaking IE sidebar float */
}


The float value just tells the div which side of the outer-wrapper to go to, you'll see on the other sidebar that this was set to go to the right. Now that we've set the style for our div, we need to actually create the div itself, so we have to move out of the CSS code block, and down to the HTML block, further down the page. Look for a block starting with this code:

<div id='sidebar-wrapper'>

Above this, paste the code for the new left sidebar:

<div id="sidebar-wrapper2">
<b:section class="sidebarLeft" id="sidebarLeft" preferred="yes">
<b:widget id="Profile1" locked="false" title="About Me" type="Profile">
</b:widget>
</b:section></div>

I've just added the "about me" widget to the left sidebar to give you something to fill the space in the layout editor, for when you come to add other widgets to this area, otherwise you'll have nowhere to drag your widgets to to add them to your new sidebar. You can remove this "about me" widget as soon as you've added another widget to the sidebar. Because you now have 2 "about me" sections, you'll need to delete the one for the right-hand sidebar, otherwise blogger will throw a tiz. Just delete this code

<b:widget id="Profile1" locked="false" title="About Me" type="Profile">
</b:widget>

from the right-hand sidebar div, which should now be just under the code you've just inserted.

All that remains is to copy the styles used for the right-hand side bar to the left one, so that they have a uniform style. Go back to the block of CSS code, and somewhere near the bottom you'll see a section specifically for the sidebar, starting with

/* Sidebar Content
----------------------------------------------- */


Here, you should see 4 or more styles relating to the right-hand sidebar, you need to copy these styles to the new left-hand sidebar by just adding the name of the sidebar to the list these styles apply to. So where you see

.sidebar {

replace it with

.sidebar, .sidebarLeft {

and where a certain element of the sidebar is changed, add the same element to the list for the left sidebar, so you might see

.sidebar ul {

change this to

.sidebar ul, .sidebarLeft ul{

likewise

.sidebar .widget, .main .widget {

becomes

.sidebar .widget, .main .widget, .sidebarLeft .widget {

and so on. Once you've copied all the styles for the right-hand side bar to the left-hand one, you should be pretty much done. You might want to fiddle around with the widths of the elements to make them fit better with your design, but apart from that most things should be fine. I would strongly suggest looking for a tutorial on CSS on the internet so that you understand fully what the code in your template is doing, and so you can edit it to look exactly the way you want it to without fear of breaking the template.

I hope you find this tutorial useful, and leave a comment if you have any problems with this or have a tip regarding this code, we're all here to help each other learn!

Thursday, 9 August 2007

How to design a webpage Pt I: Images

Following on from my earlier post How not to design a webpage, here's some tips for people making a webpage/blog/MySpace profile to follow to make things look a little better. I want to cover as much ground as possible, but I'll take things in small chunks, this time I'll concentrate on how to make the images on your site look as good as possible.

  • If you're using an image on your site that was originally a different size to what you're going to be using it at, don't just code the different size into your HTML, use an image editing program to actually resize the image. This is a good idea for 2 reasons: It will look better, as image editing software will resample the image (a bit complicated to explain, but it basically means that your image will end up looking clearer than just giving the image different dimensions in HTML). Also, it will mean that people will not have to download a 1.5Mb image just to see the thumbnail size you've coded into your webpage, therefore the page will load faster.
  • Anti-Alias your images. This is a basic function of most image editors, and makes the edges of text and graphics smoother. This is done at the pixel level, but you wouldn't believe how much of a difference it makes in terms of making your site feel more professional. Have a look at the image below:

  • GIF images are best for images with large areas of solid colour - diagrams and cartoons are good examples of what to use GIF images for. You can only have a maximum of 256 colours in a gif image, but to make your file size smaller, you should set the number of colours in your image to be as low as possible. One of the benefits of using GIF images is that you can set one colour to be transparent, allowing anything behind the image to show thorough, this can be useful, although unless you know what colour is going to be behind your image, it can be difficult to make this look smooth. In this situation it would probably be better to use a PNG.
  • JPEGs are better for photographs - anything where there's going to be smooth gradations from one colour to the next. You can set a level of compression for JPEG images - the more you turn the compression up, the smaller your file size will be, but the more 'blurred' your image will look. JPEG images have no transparency, so they will always be rectangular.
  • PNGs are useful where you need an image to smoothly blend with it's background. This is the filetype you'd get if you cross-bred a GIF with a JPEG. It achieves this smoothness by allowing you to set each pixel to be any one of 256 levels of transparency, from totally transparent (you can totally see what's behind the image) to totally opaque (you can totally see the image). The downsides to this are that the filesizes tend to be bigger because of this, and not all browsers support this transparency effect. Internet Explorer 6 will show the image, but anything even slightly transparent will show as grey. Firefox 1+ and Opera will both show these images correctly, as will Internet Explorer 7. If you've still got IE6, I strongly suggest you upgrade to Firefox.

Daft Searches

It never ceases to amaze me how people end up at my site, using Google Analytics, I can see exactly what people searched for on Google to find me, sometimes you have to wonder what people were actually looking for with these searches - here's just a few of the stranger ones...

  • girls on tractors
    I told you it was a big turn on for some people. This is one of the top searches that ends people up on my blog.
  • naked girls on tractors
    It just gets better.
  • frankie says your gay shirt
    Ahem. Does he?
  • avril lavigne shoes
    Obviously I'm not the only one that wants them. Why stop at the shoes though? They really aren't her best feature.
  • bamboo yellow shoe
    Even the Dutch aren't that daft.
  • blindfolded gang
    I don't ever remember writing that blog - I must have been very fucked up...
  • classy hen do in leeds
    There's no such thing.
  • hiccuping podcast
    Somebody was actually expecting to find a podcast about hiccuping??
  • how to make ninja shoes
    Everyone's after a pair of these bad boys.
  • kidman compass
    It's mine and no-one else can have it.
  • middle age woman feels ugly
    Have a Hen party, everyone else is doing it.
  • mixer+shoe
    There's better ways to DJ
  • naked indian guy
    That was just a rumor, it never actually happened.
  • party threesome leeds gem
    You can get anything on Google these days.
  • shoes tiesto
    More Dutch shoe madness. Those crazy Dutch.
  • shoes to go on your myspace page
    Err. It's a webpage, and therefore not strictly necessary to dress it. It will look crap all season all by itself.
  • sperm on shoes
    Easily done.
  • sugar paste shoes step by step
    ?
  • ugly fat middle-aged people
    Surely you don't need to search on Google to see these? If that's your thing, just come to Leeds.
  • ultra-power gay
    That's a super-hero I hope they never make a comic about. Perhaps you can buy gay electricity now. Gives a whole new meaning to the phrase "turn on the light".
  • washing up as lube sex
    That's just NASTY! Extra points if you can blow bubbles with it though.
  • what biscuits do old people like
    Stale ones.
  • website with nothing but yellow shoes
    There's a market to be cornered, clearly.
I kid you not, these were all things that people have searched for and ended up at my site - that list is only from the last month!