Dailycode.info

Short solution for short problems

Google Adsense

I placed Google adsense on this website. I'm trying to earn some money so I could pay off the hosting of this website. Please, if you read this, click on one of the adds on your right.

The system works really easy. It is very easy to implement this on every website. If you have a site or blog with several visitors per day, it could be a nice extra and it wont cost you a dime!

To check your account they deposit a smaal amout, in my case it was like 19 euro cents. Then when your earned money reaches 100$ they will deposit it on your bank account. I never had this, but you could help me get this ;-)

 Try it out yourself, the only requirement is a free google account!


Image url in Masterpages

Everytime I start a new webproject I have to Google for a solution to the image path problem in masterpages. When you use a path in the masterpage and it is relative, it won't work in subdirectories. This solution works everytime for me:

<img id="ctlHeader_LogoImage" src='<%= ResolveUrl("~/imgs/logo.gif") %>'
 alt="test" style="border-width:0px;height:37px;width:133px;" />

 

The "resolve url" command can also be used for other paths, like stylesheets, links, etc...

I hope by posting this code, it will stay in my puny brain once and for all time!


go-hiking.net

Since I'm passing many hours behind a computer screen, my body is tortured whole day long. Phisically I try to compensate this with extreme hinking. It gives me a good reason to keep my body in shape. This year we are planning to climb the highest mountain of Norway during winter time. With a budget of 300€ we will be away for a week. This means that we look for the most cheap way to travel and hike. Instead of buying expensive equipement, we use basic things. For example we will use 2 low quality sleeping bags to fight the cold instead of one expansive sleeping bag. This will provide valuable information for the average hikers. Follow our project here.


Winter hike

Besides being nurdisch, I'm an active christian and a hiker. I try to do one big hiking trip every year. This year I'm going to hike in the winter. Together with 2 friends I'm trying to climb the highest mountain of norway. Using only basic equipement and sleeping in a tent. You can follow this trip on this sharepoint 2003 site.  This site is no longer available!