Removing the stubborn compatibility view icon

Posted in
HTML, Webdevelopment


1 Comment

Yesterday someone I know complained that the layout of our site (leadingcourses.com) was broken in Internet Explorer 9.

Of course my own IE was showing no problems until I was playing with the compatibility view.

The button is so close to the refresh button, it happens more than once people click it by accident, breaking the fine layout of a site to something IE7 alike

I was reading some blogs and found that everything was in place already to hide the icon.
But it was still there.
There was no way to get rid of the compatibility view icon. It just would not go away..

Until I remembered I was using the following html tag:

<!DOCTYPE html>
 <!--[if gt IE 8]><!--><html lang="en"><!--<![endif]-->
 <!--[if IE 7]><html lang="en" class="ie7"> <![endif]-->
 <!--[if IE 8]><html lang="en" class="ie8"> <![endif]-->
 <head>
 ...
 <title>...</title>
 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>

This is very handy as you just say

.ie7 header {
   background-color: #000;
 }
 .ie8 header {
   background-color: #f00;
 }
 ...

So I have to replace this by doing:

 header {
   background-color: #f00\9; /* IE8 and lower*/
   *background-color: #000; /* IE7 and lower*/
 }
 ...

Reducing the html to

<!DOCTYPE html>
 <html lang="en">
 <head>
 ...
 <title>...</title>
 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>

This fixed the issue for me, I hope it helps.

Leadingcourses.com launches widget for search

Posted in
CSS, HTML, JavaScript


Leave a comment

As of today everybody offer their visitors a quick way to search through more than 7,000 golf courses in europe which are listed on leadingcourses.com.

More info can be found on: http://en.leadingcourses.com/i/search-widget/
leadingcourses.com


 

 

 

 

 

 

My usage of !important;

Posted in
Uncategorized


Leave a comment

To be honest, it is only since a short time I actually make use of !important. Most of the time I’d kick it out of my css directly, but I found some some cases where it actually makes sense!

Well properties like !important exist for a reason, well I can actually think of 2.

  1. To give people like me a job. (Yes I’ve actually seen a stylesheet of +1k lines where almost half of the styles where ‘infected’ with !important.)
  2. To do create some generic layout.

That special thing is something I’d like to share with you guys.

Continue reading

jQuery datepicker, how to disable one day?

Posted in
JavaScript, Webdevelopment


Leave a comment

Today I needed to disable one day in the jQuery ui datepicker. I did some research, and I found out, it is actually much simpler than I thought. There is something available in the plugin itself ($.datepicker.noWeekends).

The actual code I needed is like this:

$('#trigger-datepicker').datepicker({
        beforeShowDay: function( date ) {
 var ignoreDay = 0; // sunday === 0, monday === 1, etc
return [(date.getDay() != ignoreDay), ''];  }  });

Enjoy! (I do at least ;-))

Preloading an image or sprite and make it load fast

Posted in
JavaScript, Webdevelopment


Leave a comment

Recently we did a new re-design for leadingcourses.com. One of the goals was to make the site fast. As I am a (freelance, yes, I can be hired ;-) ) front-end developer, I wanted the front-end to be as fast as possible with as little effort as possible.

I already read a lot of articles written by Steve Souders and Stoyan Stefanov about site speed. A lot of stuff went in my head for that, and now I will just type it out so it is written down.

In this post the steps I took to make our sprite load faster.

Continue reading

Pictures of Albania

Posted in
Foto's


Leave a comment

It has been quiet for a while in this blog. With a reason. At first our lovely baby girl was born. And second I was very busy with the new version of http://www.leadingcourses.com.

In April I went to visit Albania and took some nice pictures. Currently I use my 50mm as a default, with which very nice effects, even for nature can be made.
Continue reading

A small horizontal gallery, xfinxgallery

Posted in
JavaScript, plugins, Webdevelopment


Leave a comment

Recently I created a small gallery which enables you to add images, text or whatever and put it in a small (automated) scroller. It is quite easy to use (see below). If you have any feature requests? please let me know :-)

Requirements: jQuery 1.4.4

Version 0.6.1

  • Removed dependency on certain classname (xg-list)

xfinxgallery 0.6.1: JS | CSS

Version 0.6

  • Added automated animation

xfinxgallery 0.6: JS | CSS

Version 0.5

  • Removed empty space at end of list.
  • Added classname support
  • Added animationType
  • Added animationSpeed
  • Added active/inactive controls

xfinxgallery 0.5: JS | CSS

Continue reading

Links?

Posted in
Links


Leave a comment

Ok, yesterday I realised that I get too much links to keep track of. As most of those links are pretty useful to a lot of people I know I’ll try put them all here.

Enjoy!

Continue reading

Banners getting better

Posted in
Uncategorized


Leave a comment

After talking with some people I found that the banner-agencies actually understand the problem. They actually also have ‘a solution’. The solution is not perfect as some of the functionalities you get when implementing a banner are lost, but at least it does not block your site.

So you are pretty anxious to get the recipe right?

Continue reading

Banners getting bad

Posted in
Webdevelopment

Tagged
, ,

6 Comments

To be honest, I think banners are a good thing. Having banners on the site is an obvious way to earn money for the content you show for free.
That is the main reason why I do not have an ad blocker.

But the most recent developments in the Netherlands concern me. Banners tend to be bigger, heavier and worse, taking over control!

Today I saw a Sony banner. This banner break parts of the User Interface, slows down the site, causes scrolling problems in some browsers and of course, causes a lot of frustration with visitors due to all this.
Continue reading