Author Archive

Simple Banner Rotation in WordPress.

Have a wordpress blog and want to rotate some banners or photos?  Here is a quick and dirty way.

Go to wordpress.org and find a a widget that allows you to post PHP code.  Once you find one you like install it. You can then go to your ->Appearance ->widgets section.  I put the widget in my sidebar.  Once there you can click on the widget and it probably have a Title field which you can call it “Ads” or what ever you need.  Then it will have a text area where you can add some code.  There just put this in:

 

<center>
<?php
$bannerAd[1] = ‘<a href=”http://www.destinationlink/” target=”_BLANK”><img src=”/images/ad1.png”></a>’;

$bannerAd[2] = ‘<a href=”http://www.destinationlink/” target=”_BLANK”><img src=”/images/ad1.png”></a>’;

$adCount = count($bannerAd);
$randomAdNumber = mt_rand(1, $adCount);
echo $bannerAd[$randomAdNumber];

?>
</center>

You can add more by just coping and pasting more of the “$banner….” block of code.  Don’t forget to increment the number that is in the [ ]’s.

Hope it helps!

Finding large files in Linux.

I have a couple of web servers and the disc keeps filling.  I know, manager them!  Here is a little trick to find the large offenders if you are going through the same thing.

# du -a /var | sort -n -r | head -n 10

That line will show you the top 10 largest file/directories is taking up the most space in a /var directory/file system.  If you want to search other directories, just modify the /var path to the path you wish to search.

Hope it helps someone!

Rob

A long year.

WOW, it has been over a year since I’ve last posted.  To be honest, I forgot about this site.

It has been a crazy yet refreshing new year.  I’ve recently got back in to web scripting which has been a BLAST.  I’ve also had to leave my job. I’ll miss that place but I feel so much better stress wise.

I plan to do more updates here.  One thing I want to do more of is reviews and maybe travel tips. I play with new gadgets often so maybe I can pass some useful information off to you readers.

Type at you later,

Rob

 

Area 51 trip.

Last October I finally was able to visit the world famous Area 51.  Not a lot to see but it was an awesome trip!

Travel Life: Minnesota

I spent last week in awesome MN. I was there a few months ago and it was COLD, around 15 degrees. This time around it was 40-50’s. There was snow all over but the streets were clear.

Rural Minnesota

Rural Minnesota

I am going back in a few weeks.  I am looking forward to it.  Maybe I can get some fishing in!

iPhone day.

Hey readers,

I’ve been doing a bit of travel lately, my biggest gripe?  My iPhone battery life!

I decided to go fix this so I went down the local apple store looking for an item I saw in a magazine, the “juice pack air” from Mophie.

iPhone Battery

iPhone Battery

It has a standby mode to keep charge, 4 colors to choose from and you can charge it while its on your phone!

So far so good. I’ll let you know how it works out for me.

Update.

I was watching NAT GEO the other day. I found some more places that I need to see! Check out the Adventure list page to see the list.

A day in the woods.

A couple weeks back I spent a day up in the woods with some good friends.  There is nothing like wandering around snapping some photo’s and shooting the breeze.

Here are a few pictures from the trip:

Winter forest.

Winter forest.

High in the mountains.

High in the mountains.

Snow melt.

Snow melt.

Trash.

Trash.

The view.

The view.

Just me.

A photo my brother shot of me a couple months ago near Yakima Wa.

 

 

Rob

Rob

A site for iPhone photography.

I have been hooked on this new (to me) website, http://www.thebestcamera.com/. It is a site that works in conjunction with your iPhone and a custom application.

You take a photo, you can apply some filters and upload it to the site (as well as your twitter and facebook if you so choose). People visiting the website can vote on your photo.

I downloaded it, did a shot and uploaded. I may be hooked. Here is my profile page, vote for one of my photo’s if you ever see one that is worthy.