John's Blog

Its Just another WordPress weblog.. Really!

Jumping Site – Firefox scrollbars Fix.

  • Filed under: Code, CSS
Thursday
Oct 4,2007

Firefox does not display scrollbars unless your content overflows the viewport.
But what if your sites height keeps changing and is centerised?
This will cause your site to jump / shift slightly when scrollbars are required.

A simple fix include scrollbars!

For a mozilla/ Firefox fix use this:

html { overflow: -moz-scrollbars-vertical; }

But if you want total cross browser Id use this:

html { overflow-y: scroll; }

I`m not too sure on overflow-y cross compatibility but I think it should work ;)

Good Bye Jagex

  • Filed under: Blog
Friday
Sep 28,2007

Its been an interesting 6 months and finally I’ve finished at Jagex :)
There’s no turning back now, its make or break for both Landon and I.

Giving up our jobs and secure lifestyles, to starting up our first business! Its a daunting feeling but I know we’re both very excited and are looking forward to see where our company(s) take us.

I’ve made a lot of friends whilst at Jagex and hey, even met Landon and without his aid probably wouldn’t of considered starting up a business on my own, for at least another 2 years.

As for the name and exactly what we are planning to do; you’ll just have to wait and see, sorry.
There’s only a handfull of people that know and we`ve only given them a smaller picture of what we are actually planning! With the integration of new technologies and other services currently available to the public.

I can’t wait to start :)

Height 100% CSS Solutions

  • Filed under: Code, CSS
Wednesday
Sep 26,2007

Ok, here a quick explanation and solution for those people who keep asking these question over and over again and again.

“My element won’t expand to 100% height of the containing parent element?”

or

“Arrrghh, my element expands over 100% of its containing parent element?!”

When you start working with DocTypes (in standards mode) you need to make sure that the parent element has a fixed height or your parents and ancestor elements are set to height:100% (Without the fixed height your browser will not know what 100% is).

This will work fine when you don’t have a doctype or set the browser to work in quirks mode because the browser tries to guess what you are trying to achieve and secretly does the fix for you.

Friday
Sep 21,2007

Fed up, with using if else statements all the time?
Want to reduce your code size a bit?

Want to be able to create crazy good code like this:

//Function To Locate Nation
function locate(nation) {
	return nation != undefined
	? typeof nation == 'string'
		? (function() {
			for (var i=0; i

Use simple ternary operators a great replacement for those cumbersome if else statements.
These conditions are overlooked so many times, but can be so simple to use.

Read the rest of this entry »

Div over Applet

Thursday
Sep 20,2007

I don`t know whose genius idea it was, to give people the power to embed applets into a web browser; but, whoever it was should take another look at how a browser works!

The amount of hassle these things can cause designers is unbelievable!
True there can be some added value, but why not just create an activeX component?

Due to stupid applets, I had to rethink how I was going to do a project for a client that involved dragging layers through these mystical objects that seem to float over the top of the browser as a separate entity..

Yes thats right.. I managed it!! :)

Read on, to find out how to make transparent holes and drag layers over applets.
It even works with dropdown menus!!

Read the rest of this entry »

DIV vs TABLE height 100% with CSS

  • Filed under: Code, CSS
Wednesday
Sep 19,2007

Example of Problem

I recently ran into a rendering problem (in standards mode) with setting two backgrounds a black on the body & white on the child div with the style attribute set to height 100%.

When you load the page the design looked fine however when you scrolled down, the div appeared to stay the same height as the browser view port and was not actually 100% of the body’s height.
[Try this in FireFox - IE6 I think should cheat and will work fine with some doctypes.]

If your interested, I’ve attached the solution to my problem.

Read the rest of this entry »

Blogs Blogs blogs blogs… BLOGS!

  • Filed under: Blog
Tuesday
Sep 18,2007

Thats right!
I have finally joined the ever inevitable world of blogging. The one place where you can find out; whats actually going on, in that head of mine! View solutions to those coding problems, that you couldn’t quite get working… .. on all those stupid browsers that never really seem to follow specifications and guidelines set by the W3C (World Wide Web Consortium) because obviously all web browser developers know best and can ignore some of the most important rules that have been set.

Hey! At least it gives us designers a bit of a challenge, sometimes I think they do it on purpose :)

Why start a blog now?
Its one of those steps you just have to take; especially when you decide, its the right time to start up your own company.
I’ve always known I’d start up my own company, it was all down to timing and finding someone with the right motivation and skills. Fortunately I did when I joined Jagex Ltd early 2007.

Who’s your business partner?
Landon, he’s a good friend and someone I can rely on to help push our company forward.
Whether its programming, learning a new language in less than a day or just showing off the suite of applications to clients, he’s the guy to do it!

Hello world!

Wednesday
Nov 30,-0001

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!