SWC Header

Cablechip Solutions

web development with Unix, Perl, Javascript, HTML and web services

Title

Cablechip Solution's Blog

Litespeed - A drop-in replacement for Apache?

Our webhosts recently switched to Litespeed, a "drop-in" replacement for Apache httpd (webserver).

Except, it isn't. In theory, Litespeed follows the same syntax as Apache for the configuration files - except for the directives they don't support! And they don't document which ones they support, and which ones they don't.

So when you try something, you don't know if its not working because:

  • its not supported, or,
  • it is supported, but you didn't configure it correctly

Apache httpd does seem a little moribund of late, so a newcomer has to be good. But Litespeed is let down, seriously let down, by its documentation.

Windows Print Screen - The PrntScr Key

Capture the screen, or a window, and paste it into a document.

In brief

Print-Screen (may be PrtScr, or some similar abbreviation)
  • this copies the screen. Then paste into MS Word, Picasa, Gimp, etc.

ALT, then Print-Screen together.
  • this copies the active window. Paste as above.
Windows-Key, then Print-Screen together.
  • this copies the screen (takes a screenshot) and save it to a file in My Pictures/Screenshots

Details here

Favicons, Apple-Touch-Icons, and MS-Tiles

Once upon a time, a website had one "favicon" (a picture bookmark), and it was called favicon.ico, and life was good.

Then Apple came along, in the best Microsoft traditions of taking something simple, and making it labyrinthine, obfuscated and over-complicated, introduced a whole suite of favicons. Then Microsoft got in on the game. And Android. So now a website need loads of favicons in different sizes.

This website does it all. Upload an image, and it generates all the favicons you could ever dream of, and the HTML you need to go with them.

http://realfavicongenerator.net/

Top tip.

The favicons ideally need to be at the top level to work, e.g. www.website.com/favicon.ico - but having all these files there makes you website untidy. Solution - place them in a directory, e.g. /icons, and use .htaccess to take care of the links

##favicon pollution
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^favicon(.*) /icons/favicon$1
RewriteRule ^apple-touch-icon(.*) /icons/apple-touch-icon$1
RewriteRule ^mstile(.*) /icons/mstile$1
RewriteRule ^browserconfig.xml /icons/browserconfig.xml

Our favicons - 1 is no longer enough!

apple-touch-icon-114x114.png
apple-touch-icon-120x120.png
apple-touch-icon-144x144.png
apple-touch-icon-152x152.png
apple-touch-icon-57x57.png
apple-touch-icon-60x60.png
apple-touch-icon-72x72.png
apple-touch-icon-76x76.png
apple-touch-icon.png
apple-touch-icon-precomposed.png
browserconfig.xml
favicon-160x160.png
favicon-16x16.png
favicon-196x196.png
favicon-32x32.png
favicon-96x96.png
favicon.ico
mstile-144x144.png
mstile-150x150.png
mstile-310x150.png
mstile-310x310.png
mstile-70x70.png


A New Website Design

Our website is content heavy - lots of walk directions, maps, and updates, so space is at a premium.

We've also noticed a lot of traffic coming from tablets and smartphones - smaller, landscape orientated, with a touchscreen, without a mouse.

So it was time for a redesign, something brighter and bolder, and smartphone friendly. With responsive design. This is the current buzzword. It means responding to the users device - e.g. if the user has a small screen width, display a narrow ad and smaller images - and if the user has a large screen side, serve wider ads and bigger images. Simples.

Sorry, a bit of CSS, even if you are not techie, you should be able to see what's happening.


<style>
.example { background: url(small.jpg ); }
@media (min-width:500px) { .example { background: url(medium.jpg); } }
@media (min-width:800px) { .example { background: url(large.jpg ); } }
</style>


Also, Windows Metro style flat icons with bold colours are in at the moment, rather than ones with Photoshopped embossed shading. The guys at DesignModo.Com have produced a cool free Flat UI pack (based on JQueryUI) which includes everything you could want. It has some nice colour swatches which I might yet use.

I particularly like turquoise on midnight.

While looking for a new drop down menu layout I chanced upon a tutorial, and from the same site, an even cooler tutorial for CSS breadcrumbs

I cannot finish without mentioning a cool start up http://pagefair.com/. They have a system for Ad Blockers. Lots of websites, including our are ad supported. Now if you use an ad blocker (I do myself!), you are freeloading. Pagefair have a system that inserts a bit of Javascript on your page. If it detects an adblocker, it asks you to unblock the page, donate a few dollar, or be reminded again in a few weeks.

Rather than customising all these ity bity things, its maybe its worth going the whole hog and using Bootstrap - combines mobile friendly CSS and Javascript UI widgets like drop down menus and tabs. Another To Do.

Welcome

Welcome.

This will be a bi-polar blog. News about walking in Southeast England, and techie stuff about being a webmaster.