Draw circle overlay in all points in gmap from Radius in a CCK field | Dynamic gmap Macro in Views

· konordo
Lately I needed to add a circle in every marker in a gmap provided by Views. So in order to achieve this, I filled in the Macro textarea of the Style:Gmap settings of the View with the following code. But first, I added the field that contains the Radius value and excluded it from Display, to make the value available in the view result set. This value was in miles, so I made the conversion from km as well.

How to install drush

· konordo
In this example, we will install drush under the directory /usr/local/share/. The path is not really important as long as you adjust the following commands accordingly. If the directories do not exists, we create them:

sudo mkdir /usr/local/share/
sudo mkdir /usr/local/bin/
And now it time to download and extract drush. Make sure that you have the latest version available and replace the url in the command accordingly. We also create a symlink so that we can use it everywhere without typing the parent path all the time...


Views: Display all nodes that have sibling terms (i.e. terms under the same parent) .

· konordo

While working on an extra requirement for metalera.gr, we needed to do the following:

When viewing node/xxx, we would like to display all nodes that have terms that belong to the same parent as the one we currently visit. Let's say for example, that we have the following parent:

Colors

--red

--blue

--green


Node/xxx has the term green assigned. We need our view to display all nodes that have red or blue as well. 


To achieve that, we first create a new view, then:  


How to create divs with rounded corners, using only a lightweight circle graphic and a combination of xHTML/CSS

· konordo
* Create a square image depicting a circle, using as a side double the radius of the desired round corners' width(You can do that with any image editor, i.e. mspaint). We 'll use 16px radius for our corners in our example, thus we'll be needing a square image 32x32 pixels depicting a circle(with a radius of 16px obviously), with the same border/backround color combination, as the divs we'll inclose.

i.e. -> http://img137.imageshack.us/img137/3000/circleq.png

CSS Code: