Arkiv för kategorin ‘Uncategorized’

Forms that look great

september 22, 2009

It has always been a hazzle to make forms that look like the designers want to. There are never time to replace them with new nice graphical look with javascript, so .. they look as they look.

Now, my colleague at work discovered this:

Niceforms

I love whenpeople share their code::)

Snap shots – exiting but with ads.

september 21, 2009

Link to snap shot 

Link to overwiev page – this is what it looks like

Snap shot provides layers that look like speech bubbles when you hover an external link (place your mouse over a link) with a preview of the website. You can also use it for explanation of words to explain it in wikis, or put a link to youtube movies and play the movie directly  in the ”speech bubble”.

The best is that you can get google maps inside the bubbles. Just ad a link to the adress.

Easy to use – put a link to a javascript in the header of your website. And done.
You can also decide what kind of links that will have have snap shots. For example only external links, internal links, certain domains and so on.

So what is the disadvantage.. of course there are always something, when it´s free and fantastic…

Well, you have to show ads inside the bubble if a company has bought ads that is relevant to the content that you are showing…

Only to educational and governmental  institutions has exemptions  from showing ads..
http://www.snap.com/snapshots_faq.php

Statistics are fun. Internet more common than newspaper and TV

augusti 26, 2009

Year 2002 there were 20% of the Swedes who had broadband. Today there are more than 70%! Actually more than have daily newspaper.

Among those who are between 25 – 44 they spend almost 2 hours on internet every day, as much as they watch on TV. Even a few percent more…

A common day 80% of this segment use internet. In 2003 it was only 40% who used internt. The intresting is that the watching of TV hasn´t changed. It is still about 80% as well.

jQuery columns plugin as in magazines

april 23, 2009

http://welcome.totheinter.net/columnizer-jquery-plugin/

Don´t know if it works for screenreaders…

XHTML and CSS reference

april 23, 2009

jQuery inspiration

april 23, 2009

Google Maps API – Basics

april 15, 2009

The first thing you have to do for developing with Google Maps API is to get a key.
You are required to fill in wich url you are going to develop under as well.

You can get it here:
Get Google MAP API key

Load the Map API

 <script src="http://maps.google.com/maps?file=api&v=2&key=abcdefg&sensor=true_or_false"  type="text/javascript"></script>

Set the sensor to true and don´t forget to change the key to your own.

You need a container to hold the map, for example:

<div id="map_canvas"></div>

Then you initialize the script in the body tag with:

 <body onload="initialize()" onunload="GUnload()">

And of course you write the function for this in your head element:

function initialize() {
var map = new GMap2(document.getElementById("map_canvas"));
map.setCenter(new GLatLng(37.4419, -122.1419), 13);
}

The first row makes an object of the GMap class and place it in the div ”map canvas”.
Secondly we decide what area of the world map that will display. The number 13 is the zoom level of the map.

Where am I?

To find the longitude and latitude of the map use the getBounds() method to return the GLatLngBounds value
var where = map.getBounds(GLatLngBounds);
alert(where)

Controls on the map

map.setUIToDefault();

setUIToDefault describes the user interface of the map: zooming, controls, mapview etc.

View the map as satellite-, map-, hybrid- pictures

map.setMapType(G_SATELLITE_MAP);

Satellite view : G_SATELLITE_MAP
Normal map: G_NORMAL_MAP
Hybrid map: G_HYBRID_MAP
There are two more settings: For an array of all three and a map based on terrain info.

Place markers on the map

 var point = new GLatLng(37.4419, -122.1419);
var marker = new GMarker(point);
map.addOverlay(marker);

The last row: map.addOverlay method add a marker to the map.
new GMarker makes an instance of the class where the latitudes is given through new GlatLng

Info window on the map

You can create info windows with simple text or with HTML with openInfoWindow.
The default window looks like a comic strip bubble and you can close it if you want to.

 

ZoomLevel

var zoom = map.getZoom();
alert(zoom)

Use the method getZoom()

Animate the map – pan to another location or zoom in

use the panTo method with new GLatLng method

map.panTo(new GLatLng(37.4569, -122.1569));

Egen webbserver – del 3

april 15, 2009

Herregud. Kan Loopia göra det mer krångligt och svårt att begripa deras tjänster? De skulle behöva en genomgång. De som dessutom är en av de största…

Hur som helst. DynDNS var enkel att konfiguera när man läst instruktionerna på Loopia hur man skulle göra. Men därefter att begripa hur fanken DynDNS:en uppdaterade Loopias inställningar för min domän och framför allt VAAART och HUUUUUUR? Kan Loopia göra sina tjänster mer obegripliga eller?
Efter mycket klickandes överallt och hit och dit på Loopia så såg jag att DNS:en hade uppdaterats automatiskt av DynDNS.

Bra, men det fungerade fortfarande inte.

Aha, då var det namnservrarna som inte var ifyllda med hänvisning till Loopia. Ja ja – trodde det blev Loopia automatiskt när jag köpt domänen där.

Sen dröjde det bara några minuter så var www.favoritkokboken.se igång.

Egen webbserver – del 1

april 15, 2009

Jahapp, nu är det dags för min första server hemma. Efter de två senaste webbhotellen wpsyd och 99kr.com trasslade med fakturor och tog betalt fast jag avslutat, så har jag beslutat att ha min hemsida hemma.

Så nu börjar installationen av apache på min gamla Windows XP burk. ”J” rekommenderade denna variant: Win32 Binary without crypto (no mod_ssl) (MSI Installer).

1 minut senare…oups det var enkelt. redan klart.

Egen webbserver- del 2

april 15, 2009

Härligt. Nu har jag lyckats port forwarda trafiken in via vår router LinkSys till min ”hemmaserver”.
Fick ställa in fast ip adress på denna burk, så att inte routern tilldelar den här burken dynamiska adresser. Och så se till att alla internettrafik in mot routern vidarebefodras hit.
I inställningarna för routern så hittade vi ”Tillämpningar och spel”, där skrev vi in ipadressen och valde port 80. Och aktiverade förstås..

För att säkerställa att det funkade, gick vi in på whatismyip.com och fick den externa adressen till routerna.
Men naturligtvis – glömde att stänga av windows brandvägg burken + att dela ut rootmappen på apache servern.

Men nu funkar det.

Nu är det bara del 2 kvar.
Installera DynDns och skaffa konto på Loopia.

Be tuuned.