Go to content Go to navigation Go to search

Brokenwire.NET::System

Site updated
· 2010-08-25 15:26 by Thijs Kroesbergen for Brokenwire.NET

Just upgraded this site to a new version of textpattern. I think everything still works fine, but please leave a comment if you find anything suspicious.

Permalink -

New feature: Webslice
· 2009-04-20 14:31 by Thijs Kroesbergen for Brokenwire.NET

Brokenwire.NET now has it’s own webslice. You may wonder what a webslice is. Remember 1997 ? That’s when we had snippets of web pages on our active desktop! Well a web slice is just that, it’s a piece of information from a site inside a small window in your browser. Internet Explorer 8 is the only browser that supports these things right now.

When you have installed the slice on you browser’s favorites bar it will look like this:

So if you have IE8 you can click on the small link in the right sidebar on this site to add the Brokenwire.NET webslice to your own browser.

Creating such a slice is very easy, with some help of this blogpost about webslices I was able to do this in 10 minutes.

The basic HTML structure:

<html><head>
<title>Page Title</title>
</head><body>
<div class="hslice" id="techologynews">
<h2 class="entry-title">IE 8 web slice</h2>
<div class="entry-content">
<p><a href='#'>Link 1</a></p>
<p><a href='#'>Link 2</a></p>
<p><a href='#'>Link 3</a></p>
</div></div>
</body></html>

The basic rules:

    1. The WebSlice must use the class name hslice in the container.
    2. Each WebSlice must contain an ID in the container. This is how the WebSlice will be differentiated from others on the page.
    3. The WebSlice must have at least one entry-title element defined. This will be displayed both in the page and in the feed button that appear in the Favorites Bar when a user subscribes to the WebSlice.
    4. While not required, each WebSlice should contain at least one entry-content element. This is the information that will appear when the user selects the WebSlice from their Favorites Bar.

There is also an official Microsoft whitepaper about webslices.

I wonder if anybody is actually going to use this, but it was a nice thing to play with for a bit.

Enjoy!

Permalink -

Tip: Batch files with over 9 parameters
· 2008-10-14 20:27 by Thijs Kroesbergen for Brokenwire.NET

This has been around for ages, but it saved a us lot of work today (once we figured this out)..

So when you are writing a batch file (.cmd file) to automate some stuff you might run in to the issue that you can only retrieve the command line parameters up to number 9, by using the %1 to %9 variables.

Example:

@echo off
SET ONE=%1
SET TWO=%2
SET THREE=%3
SET FOUR=%4
SET FIVE=%5
SET SIX=%6
SET SEVEN=%7
SET EIGHT=%8
SET NINE=%9

So what do you do when you need number ten and up? %10 and up don't exist! Solution: You use the "shift" command!

Every time you call SHIFT the parameters will move 1 position, so if you call it ten times...

SHIFT
SHIFT
SHIFT
SHIFT
SHIFT
SHIFT
SHIFT
SHIFT
SHIFT

then you can retrieve number 10 and up..

SET TEN=%1
SET ELEVEN=%2
SET TWELVE=%3
SET THIRTEEN=%4
SET FOURTEEN=%5
SET FIFTEEN=%6
SET SIXTEEN=%7
SET SEVENTEEN=%8
SET EIGHTEEN=%9

How about that! (Be honest, did you know this?)

Permalink -

A NASty device
· 2008-04-05 21:09 by Thijs Kroesbergen for Brokenwire.NET

As of today I am the proud owner of a 1TB network attached storage device.

It’s name is "CH3SNAS". I’ve used two 500 gb Western Digital GP harddisks. These disks are made to be energy efficient. I thought that would be a good thing for a device that will be always-on. And the disks won’t be stressed out much because all data has to travel through the network before hitting the disk. So speed is not an issue. Besides that: more power more heat, more heat more cooling and more cooling == more noise and dying disks.

I’ve also upgrade the network switch to gigabit because the old switch was dying and its not a lot of fun to reset your switch every few minutes while trying to download something. Now the CH3SNAS is the only 1000mbit device connected but now I can upgrade the others gradually.

This device also has an UPnP AV Media server on board, so I can easily browse through all my movies, music and pictures. I’ve also found a nice UPnP compatible music/movie player for my IPaq (but it’s not free so better suggestions are welcome!).

It also has a scheduled download option, which means that the NAS can download stuff while your PC is off.

Maybe the most important thing this device can do: it has support for so called "funplugs" (the hardware is almost identical to the D-Link DNS-323 NAS, only the CH3SNAS is cheaper). Which means that you can add your own software to it. The thing actually runs Linux and has quite a decent CPU so there’s all kind of fun things to run on there. I’m thinking bittorrent, hellanzb, slimserver, ssh, nfs-server… a lot to play with ;-) Oh and there’s a new firmware out soon as well.

Permalink -