Archive for June, 2009

25
Jun

Blacklists and Spamhause

   Posted by: Richard    in Tech stuff

I see Himself has been having a side swipe at my clients.

Maybe not the best of business ideas, but I doubt that they read his rants, so hopefully no damage will be done.

There have been a number of complaints from clients who have been unable to send mails from their accounts.  As they share a mail server with others who have no problems, this led to some investigations.

All these clients complained of the same symptoms – they were able to receive mail, but were unable to send any except via the web interface.  In each case, their mail client configuration was correct.  If I set myself up an account on their domains I was able to send with no problems.  So what was the cause?

I did some sleuthing and found the problem.

In each case, their local IP had ended up on a spam blacklist, Spamhause seem to be one of the major ‘offenders’ here.  The latter seem to be very enthusiastic in their efforts which is fair enough but it does lead to problems.

One client in particular consistently fails to send mails. 

His IP address is listed on Spamhause who claim his PC contains malicious software.  We checked the PC rigorously and found it to be clean.  His is the only device using that connection.

As his ISP provides dynamic addressing, I checked the other IP addresses in the block.  All were blacklisted on Spamhause, therefore reconnecting to obtain a different IP wasn’t going to work.

I contacted the ISP and explained the situation.  They claimed it was the mail server that was blocked.  I told them it was my server and assured them that not only was it clean but that it did not appear on any blacklist.  They finally conceded that it was their addresses that were at fault.  They maintained that it was up to my client to contact Spamhause.

Now, we have a bit of a conundrum here.

If my client gets his IP cleared, his connection is going to fail the next time he gets a new address. 

The ISP maintain they can’t clear the addresses, as they cannot give any guarantee that the equipment using those addresses is clean.

Presumably the cause of this mess is that one of the ISP’s clients has an infected machine and each time he is allocated a new address, Spamhause blocks it, until all the IP addresses in the range are blacklisted.

It is one of the lesser known side effects of viruses and spam and it is damned irritating.

21
Jun

Writing a blog – customising

   Posted by: Richard    in Blogging

If you have installed Wordpress, you are presented with couple of themes.  They are not particularly exciting, and most people want something that looks a little more individual.

There are literally thousands of free themes out there.  If you are running the latest version of Wordpress (and I hope you are) then downloading these themes to your site is simplicity itself.  You can have a preview of the new theme and if you like what you see, you can activate it.

However, this is still not enough for most people.  They want something that is individual to themselves, whether it is a personalised header graphic or an entirely new colour scheme.

Customising a Wordpress theme can be quite simple.  The only requirement is that you should have a rudimentary knowledge of HTML and CSS.

My own personal method of creating a scheme that I like is to browse the Web for a theme that has all the rudiments that I require.  I will then set about customising it.

In the majority of cases, themes follow a similar pattern in that the basic files are common to most themes.

The main files which require moderation are usually

  • header.php
  • Footer.php
  • sidebar.php
  • style.css

These are found in the folder wp-content/themes/yourtheme where ‘yourtheme’ is the name of the theme you are modifying.

Probably the most important of these is the file ‘style.css’.

Say for example, you wish to change the banner on the site.

The simplest method is to right-click on the current image.  It is usually a background image so you select ‘View Background Image’ or ‘Save Background Image’, depending on your browser.  One way or another, this will give you the name of the file – usually something like ‘banner.jpg’ or ‘header.jpg’.

Having retrieved the name, (you needn’t save the file or anything else), you then search through ‘style.css’ until you find a mention of that file.

For example, the top image on this site is ‘header-bg.jpg’ and it is located in the ‘images’ directory.  If I search through the ‘style.css’ file (which is pretty large) I find the following:

#head {position:relative; width:990px; height:250px; margin:0 auto; text-align:left; background: url(images/top-right-bg-repeat.jpg) 90px 0px repeat-x;}
.crack {position:absolute; left:0px; top:0px; width:990px; height:51px; background: url(images/crack.jpg) 627px 0px no-repeat;}
.header {width:627px; height:250px; background: url(images/header-bg.jpg) no-repeat;}
.logo {position:absolute; left:0px; top:115px; width:627px;}
.logo h1 {font: bold 26px/120% Georgia; color:#602600; padding:0 0 10px 20px; margin-right:16px;}

I can therefore change that line to use a different file, though it should be noted that the alternative image must have dimensions of 627 pixels wide and 250 pixel high, otherwise there may be problems.

Essentially any image in the scheme can be changed this way.  Of course another method is to just rename your new file to that of the existing one, and then overwrite it (So I would rename my personal file as ‘header-bg.jpg’ and overwrite the existing file).

Colours are slightly harder to change.

Colours in CSS files are invariably written in the form #112233.  This is in the format Red-Green-Blue so that the 11 refers to the level of red (on a scale of 0 to 255), 22 refers to green and 33 to blue.  However, it uses what’s called hexadecimal notation which means that 255 becomes FF.  Without going into too much detail, counting in Hexadecimal follows the following pattern:

1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F, 10, 11 …..  19, 1A, 1B … 1F, 20 …

In other words, F in Hexadecimal is 16 in denary (decimal), and 10 (in H) is 17.

So your colour should always consist of six characters ranging from 0 to 9 and A to F.

As an example of the two limits, Black is #000000, and White is #FFFFFF.

Examples of that notation will crop up throughout your ‘style.css’ and any of these can be changed to provide your desired colours.  The biggest problem is determining a) the code for the number you require, and b) which bit of code refers to the colour you wish to change.  Sometimes it can be obvious – in the code extract above, the font in the header (logo) is set to #602600, so changing this will change the colour of the words “The Other Fellow”.

Customising a theme initially can be a case of trial and error, but if you become familiar with a particular theme, you will soon learn which elements are which and what colour refers to what.

Initially it can be a case of pot luck, but with a bit of practice, you should soon be able to tweak your theme to the style you wish.

Good luck!

15
Jun

Absence makes the heart grow fonder?

   Posted by: Richard    in Blogging, Health

I really am my own worst enemy.

I announced a while ago that I was going to try to boost this site a bit, and then what do I do?  I go and leave it unattended for weeks on end.

Maybe I chose a bad time.  The old medications are fucking up the head a bit, so writing isn’t as easy these days.  Maybe a trip to the old Horse Doctor is the answer to my ranking problems? 

I wrote a few months ago about RLS.  This has become progressively worse over the last while.  I am taking medication to suppress the symptoms, and that medication is doing a grand job.  I am getting a good nights sleep, and the symptoms during the day are bearable.  However that same medication has the side effect of slowing the brain to a crawl, so that the simple act of writing a short post like this becomes quite a task. 

It may seem reasonable, that if a medication is having deleterious side effects, that I should come off it.  However, you can take it from me – I would rather the side effects to the incessant RLS!!

So it is time to make an effort.  It is time to squint my brain and try to update this a bit more.

Time will tell.