Live Demo of Captive Portal Design

Aruba Portal on an iPadIn my previous post, I showed a very simple design for an Aruba captive portal that is usable on small handheld screens (like a cell phones) as well as full size browser windows. In this post, I had directly pasted the HTML code (with embedded CSS). This actually had a couple of drawbacks. First, WordPress didn’t really handle the code very well. Part of the reason I pasted it right in the post was to have the code stylized by GeSHi. Unfortunately, GeSHi didn’t properly highlight the CSS. This also ended up making the post really long and there’s at least a few places where it mutilated the code. And second, embedding the code in a WordPress post also had the drawback that you couldn’t see how the page looked other than in my screenshots.

So I’ve now uploaded the code as a normal webpage. You can view it in a window sized like a phone screen [Pops up new window]. Once this window opens, you should be able to resize it in order to see how the page will look at different screen/browser sizes. Or you could view it in your current browser window (if you’d like to download the HTML, you should be able to right-click the link to get an option from your browser to save the target).

Simple Responsive Design for Aruba Captive Portal

At work, we have an Aruba wireless system. This system has the ability to have multiple SSID’s available. One of those SSID’s is for guest access. We require that every guest has a username and password to access our wi-fi system. This requires a captive portal. Aruba supports these captive portals quite nicely, but their authentication pages leave a lot to be desired. I recently spent some time searching Google for some sample templates that work well on cell phones, tablets and computers. While I did find some information it was mostly vague information (yes, it’s possible) or based on using other web design templates and uploading the necessary files.

This isn’t what I wanted. I really just wanted a very simple page that had a login form and our Usage Policy (not a link to it, the actual policy on the page). If it was on a tablet or a PC, I wanted them to use the screen real-estate to show them both side by side. If it was on a phone, they should be stacked to avoid zooming. I couldn’t find anything that did quite what I wanted, so I wrote my own. Just in case there’s somebody else looking, I decided to post it here.

First, a screenshot of how it looks on an iPhone 6:
Aruba Portal on an iPhone

And an iPad:
Aruba Portal on an iPad

There are actually two more “modes” not pictured here. They are both only applicable to being displayed on a computer.

There is one mode that is in between phone and tablet size. The only time it should be used is if somebody opens a very small browser window. It condenses the login form to take less horizontal space, but still keeps the policy text to the right of the page.

The second mode is for a very large web browser windows (more than 1,200 pixels). This mode simply keeps the max width at 1,200 pixels and displays nothing to the right of that boundary.

The magic in all of this are the @media CSS queries. These media queries are a function of CSS3 and are not supported on older browsers such as IE 8 (the most recent version available on Windows XP). Because of this, I put most of the style (colors, borders, etc) outside of the media queries and then shifted items around using the media queries. The page may not respond exactly as it’s supposed to in older browsers (for example, the items don’t stack properly when the width drops below 480 pixels in IE8), but the page should still be functional.

The code is available after the break. You are welcome to take this code and modify it for your needs.

UPDATE 11-Feb-2016: Instead of embedding the code in this post, I now have a Live Demo page setup.

Loading a Windows 7 User Tile using the picture in Active Directory

The Explanation

Back in 2010 as Microsoft was putting the finishing touches on Office 2010, the Microsoft Exchange team mentioned that it was going to possible to show pictures in Outlook 2010. They also talked about how these pictures could be loaded directly into Active Directory and Outlook would be able to pull them from the directory. It didn’t take me long to make the required schema change on our network at work and load a few pictures in for testing. Once I updated our system to support Windows 2008 domain controllers, the display of pictures in the beta version of Outlook started working perfectly.

Even before I got the picture display to work in Outlook, I started wondering if it would be possible to make Windows 7 automatically load those pictures for its User Tile (I actually even asked the question on the blog post by the MS Exchange Team). It seemed that this wasn’t possible. Supposedly the fact that this was desired was passed on to the Windows team, but even after Windows 7 SP1 came out there didn’t seem to be any official support for this feature. And as far as I can tell, none is forthcoming.

The other day, I happened across a post by a guy named Joco where he detailed an undocumented API in Windows 7 that sets the User Tile. He also included some sample C# code that you can execute with command line arguments for the username and the picture location. However, I want to load the pictures directly from AD and I’ve done most of my “programming” in Visual Basic, not C#. So, I took his sample code, translated the API declaration to VB and added some code to retrieve the picture from Active Directory.

The Executable File

For simplicity, I’m providing an executable file already compiled against .Net 3.5 (which comes with Windows 7). This executable is signed by a CA Cert code signing certificate. If you do not have their root certificates installed, Windows will tell you that it’s an invalid signature.

To use this file, it can be simply be run by the user. You can launch this automatically as part of a login script (which is how I use it). The logic script application I use also allows me to hide any output so the DOS box never gets seen by our users.

Note: The icon used in this executable is licensed under the CC Attribution-Noncommercial-Share Alike 3.0 license. I’m open to using a different icon if I can find one a little more representative of what the program is doing.

Source code and some basic directions for using it can be found after the break.

Continue reading “Loading a Windows 7 User Tile using the picture in Active Directory”

From BlackBerry Pearl 8130 to Palm Pre

As previously mentioned, I recently switched from a BlackBerry Pearl to a Palm Pre. I’ve been using the Pre for a little more than a month now and figured I put my thoughts about the switch up. I’ll follow roughly the same format I did when I switched to the BlackBerry. Unlike last time I did this, I’ll provide an outline here near the top with links down into the specific sections.

Continue reading “From BlackBerry Pearl 8130 to Palm Pre”

Got a Palm Pre

Thanks to my employer, I now have a Palm Pre. I’ve been eyeing one pretty much since Palm announced it. For a while I was debating between the BlackBerry Tour, the soon to be released HTC Hero and the Palm Pre. I had pretty much decided on the Pre, but thought I had a little more time before I could get it. Turns out I was able to get it sooner.

Similar to when I got the Blackberry, I’ll do a pros and cons post soon. Also similar to when I got the BlackBerry, this post was made from my phone.

Using DreamHost for offsite backup

For quite some time now I’ve been taking a pretty big risk with a lot of files at home. I have a linux box that I run samaba on in order to share files with my Windows machines. These Windows machines map that share as their “S” drive. Once upon a time, this 120GB drive had a twin in the box with it and everything that was on one drive was automatically placed on the other drive (using software RAID 1). Years ago, that mirror was broken and never restored. So, all my data was setting on one hard drive (this included all of Haylee’s Pictures, a bunch of other pictures, all my MP3 files, and a few other random files). I could always dig my CD’s out and re-rip them to get the MP3 files, but Haylee’s pictures were a little harder to replace. I mitigated this risk by occasionally going in and burning these pictures to a DVD, but that required some manual work to do the backup. It also left open to loss anything that was created more recently than the last backup.

A couple months ago I moved Haylee’s picture site off the server in our spare bedroom and onto DreamHost. This helped out with the risk to Haylee’s pictures because most of them had also been uploaded to that site. But not all our pictures are uploaded to that site and it didn’t do anything for the other types of files on the S drive. To make matters worse, some of the stuff on that S drive isn’t really for public consumption. Probably the most personal thing on that drive is our Quicken backup. While it’s not the end of the world if somebody gets ahold of that, it’s still not something you generally want “out there.” So what I needed was a secure and automated way to back up all my files. I had toyed with the idea of using an old DLT drive I had laying around, but getting that to running was a lot of work and the DLT drive isn’t exactly quiet. Due to some other recent developments, we moved the computer out of its own room out into the living room. A loud tape drive really doesn’t work in that environment. So I needed something slightly different.

Enter GnuPG, DreamHost’s Personal Backup feature, and some perl scripting magic.

Continue reading “Using DreamHost for offsite backup”

Geocaching

Over Labor Day weekend, another seasonal at the campground mentioned that they had been geocaching recently. My wife had been geocaching before with TJ, though I had never been. When we got back from camping over the weekend, she said that she really wanted to geocache. In preparation for my trip to Iraq back in 2004, I bought a Garmin Rino 120 GPS. I actually never used it while I was there, but I still had it. We dug it out from the bottom of the closet and figured out how to add a couple points to it. We set out that evening to do our first cache: Savage Animal. It took us a little while to figure out how all the equipment worked, but we did find it. I had brought my laptop along with me, so that helped us out of a pinch. Good thing I brought it along.

Since the 1st, we’ve found 7 caches. Unfortunately, we’ve also made 7 appempts that didn’t work out. If you’d like to follow along, I set up a blog at http://geocaching.steenhagen.us. You can either check out blog periodically or subscribe to the RSS feed if you’d like. Or you can completely ignore our Geocaching adventures :).

From PPC-6700 to BlackBerry Pearl

As I mentioned before, I’ve now been a BlackBerry user for two and a half months. So, here are some of my thoughts having come from the Windows Mobile world.

Things I actually liked about Windows Mobile that I’m missing now

Chat Like Text Messaging

To be fair, when I first started using my PPC-6700, Windows Mobile didn’t have it either. Palm was the first to bring threaded SMS to the Windows Mobile world (porting it over from their PalmOS version). However, on my latest update to Windows Mobile 6.1, I didn’t even have to jump through the hoops of finding a CAB for the Palm application and installing it, it just worked on my phone. Compare the screen shots to see just how much more useful the threaded SMS is.

Windows Mobile 6 Text Messages
Windows Mobile 6 Text Messages
Text Messages on the BlackBerry
Text Messages on the BlackBerry


Larger Display

As can be seen on the side-by-side screenshots above, the Windows Mobile phone does have a slightly larger display. They are the same width, but the Windows Mobile phone was about 60 pixels higher. Of course, the BlackBerry phone uses the space for those 60 pixels to give me an always available keyboard complete with tactile feedback and it’s impossible to have everything.

Voice Command

Microsoft Voice Command was actually a pretty good program. It seemed to recognize was I was saying better. It also seemed to flow better than the voice dialing on my BlackBerry phone. I also liked that if I had my Bluetooth headset in, Voice Command would read the subject for any high priority email messages I received. Granted, I’m comparing the pay version of Voice Command to the version that comes free with the BlackBerry… and the free BlackBerry application is a lot better than the free one that came on my PPC. But I can’t say that I’ve come across a better voice command for the BlackBerry (though vlingo is promising).

Direct IMAP/POP3 Email Retrieval

When it comes to email, the BlackBerry wins in most categories, but this one kind of goes to Windows Mobile. Being in the Army Reserve, I have what’s called an AKO account. Among other things, this provides an email address. This email can be retrieved either using webmail or from an email client that supports IMAP or POP3. Research In Motion has a service that allows you to have their servers check up to 10 email accounts for you and send any messages you get to your BlackBerry. Unfortunately, this requires them storing your password. The government isn’t really a fan of this. Other than that one minor tidbit, push email on the BlackBerry is better. It’s also easier on the phone’s battery (IMAP/POP direct from the phone has to constantly check for new message, BlackBerry’s push doesn’t really do anything until there is a new message). Once I no longer have an AKO address to worry about (a touch over a year from now!), this won’t be a concern anymore.

Syncing the “Read” status

When I used Windows Mobile, if I read a message in Outlook on my desk, the next time the phone synced with the Exchange Server, the message would be marked as read on my phone. Not the case with my BlackBerry. It does work the other way around (when I read a message on the phone, it gets marked as read on the sever). I liked that on Windows Mobile, it worked both ways.

Syncing of contact pictures

This was one of those “hey, that’s cool” type things when I found out how to do it, but now that it doesn’t work on my BlackBerry phone, I miss it. Any contacts in my Outlook contacts folder that had a picture associated with them would have that same picture associated with them on my phone. So when that person called me, their picture showed up as part of the caller ID. Where this really started to shine is when I found a program that would go out to Facebook and grab pictures for anybody I had in my Outlook contacts. Shortly after the program ran, those pictures would be on my phone ready to be caller ID photos. My BlackBerry, of course, has the feature where you can associate a picture with a contact and when that person calls you get that photo of them as part of the caller ID. It does not, however, get that picture from the contact in Outlook.

No separate “Windows Mobile” data plan

In order to get BlackBerry service, I have to have a BlackBerry plan. Because I connect to an enterprise server, I have to have an even more expensive plan. I pay $39.99 per month for the data on my BlackBerry compared to the $7.50 per month I was paying for data on my Windows Mobile phone (it was on an older data pacakge that Sprint no longer offeres). If my employer wasn’t willing to pay for the better email experience, there’s no way I’d have this plan and thus this phone.

Things I like better about the BlackBerry

So now that we’ve got the negatives out of the way, let’s talk some about the positives of my new phone.

Size

This is a huge one (no pun intended… really). My old phone was a brick. I powered it up today to get a screen shot of the SMS client and… wow. Now sure, there’s a number of phones that run Windows Mobile and not all of them are bricks, but I think most of them are… and the one I had most certainly is. My BlackBerry is the Pearl. It really is a nice size phone. Sure, I had to sacrifice the full QWERTY keyboard and it has a smaller screen than most other BlackBerrys, but it’s so easy to carry. It’s light. When I hold it up to my ear to talk instead of using a headset it’s actually comfortable. With my old phone, I often felt like I was holding a brick up to my ear. If possible, I avoided using it if I didn’t have a headset available (it wasn’t bad to use with a headset and Voice Command, as I mentioned above). With my BlackBerry, I’ve used it many times without the headset and it’s really no different than using any other candybar style phone.

New since visit indicators

Not only does my BlackBerry tell me how many messages a particular program has, but it also tells me how many of them are new since the last time I had that program open. This is the case for email, SMS, JiveTalk (Instant Messenger), Facebook, etc. This really comes in handy as I have a tendency to not always read messages as they come in but to come back to them later…. sometimes never in the case of mass mailings.

GPS

Yes, this is also just a feature of the particular phone as I know there are Windows Mobile phones with a built in GPS and there are BlackBerry phones without GPS. But the simple fact is, my old phone didn’t have one and this one does. And for what it’s worth, I think I actually like the BlackBerry maps application that comes with the phone better than Google Maps.

Much more phone like

In addition to the size consideration I mentioned above, the BlackBerry just seems to run much more smoothly as a phone. With the Windows Mobile phone I pretty much always felt like I was “starting up the phone program” to make a call. Even though it was a cell phone, it felt more like using a softphone on the computer… it works, but it’s not what the computer was really designed to do. With the BlackBerry, I feel like it’s a phone/email device first, everything else second. It does other things quite well (with the exception of what I mentioned above), but it really shines as a communication device.

Email is a breeze

And, of course, the bread and butter of the BlackBerry. When it comes to email, the BlackBerry beats my old Windows Mobile phone hands down. Messages get delivered quicker (yes, Windows Mobile claims to have push email when syncing with an Exchange server, but the BlackBerry still seems to deliver faster. I often hear my BlackBerry ding or feel it vibrate before my computer on my desk (20 feet from the mail server on the same physical network as it) gets the message. There is one downside that I mentioned above with RIM’s approach to email, but if you don’t have to deal with government provided email, it’s a great package.

Battery life!!

Again, this is partly a function of the specific model phone I had, but it’s also effected by the Windows Mobile method of push email. My old phone could go about 10 hours on a full charge with normal usage. The advertised spec for it was 4.7 hours of talk time or 200 hours of standby, but I don’t see how that’s possible at all. Standby must be determined with all radios off (including the cellular radio) because even without push email running I don’t think I ever got much more than an awake day out of it. My new phone will almost get me two days of normal usage (its advertised spec is 3.7 hours of talk and 216 hours of standby). I still charge the BlackBerry every night, but at least I don’t have to charge it in the middle of the day.

Facebook Application

Sure, there’s a mobile version of facebook available at m.facebook.com, but the application provided by RIM that’s a native BlackBerry application running directly on the phone is a lot smoother and quicker to use. With it installed, it will intercept all messages from Facebook that are sent to your phone and process them within its interface. It allows you to define a special sound for Facebook notifications. But it doesn’t just receive. You can use it to write on a friend’s wall, accept friend requests (though you can’t add them to a friend list or add friend details), poke your friends, reply to and send Facebook messages and, my favorite, upload photos directly from the phone. Just take a picture and choose the option to upload it to Facebook. You can even tag friends in the photo from the phone (though I’ve yet to do this).

Different Alerts for Different Applications

Sure, every program on a computer or Windows Mobile phone can have a method for letting you choose how to be notified, but on the BlackBerry, there’s actually a way for applications to plug into the standard notification profiles. All the app then has to do is tell the phone to notify you. The phone keeps track of how you want to be notified (are you in silent mode?, is there a specific sound for that type of notification?, etc) and does it. It really comes in handy with the….

Holsters with a Sleeper Magnet

You can get a holster that contains a sleeper magnet. The phone has a sensor that detects when it’s in the proximity of this magnet and then knows whether it is in the holster or not. You can have your sound profile set up to perform different actions if the phone in the holster than it performs while it’s out of the holster. I have mine set up so when it’s in the holster all alerts vibrate but when it’s not, I get different sounds for different events. When I walk into a movie theater, I don’t need to worry if my phone is on silent or not, I just know that it’s in the holster, so it’s OK. But if I have the phone setting next to me on my desk, I can listen and tell what that notification is (so I know that Outlook is about to tell me I have a new email).

Summary

Wow, that ended up being a very long post. According to WordPress, I have 2009 words. Goodness, it’s like a mini essay.

I’m now a BlackBerry user

Almost two weeks ago now, my boss approved me getting a new phone. I had been using a Windows Mobile phone, but my boss has always thought I should be using a BlackBerry… So when it came time to get a new phone, guess what I got :). I’ll probably post some of my thoughts on the pros and cons of the transition soon. By the way, this posting was actually made from my new phone!

UPDATE (29-Aug-2008): It’s a long post, over 2,000 words, but I finally got around to it

MythTV Issues – Revisted

The other day I was going looking at some old posts in my blog and came across one that I thought might be a good idea to update: MythTV – Like TiVO w/no subscription! In it, I listed a series of issues that I had shortly after I finished my MythTV install. Well, I’ve been running Myth now for more than two years and have updated from the 0.18 version I originally installed to 0.20.2. But first, a little bit of back story of I got to here.

As I mentioned in the original post, I first installed Myth on an old computer running Fedora Core 4 as its OS. I upgraded Myth a couple times on this setup to get to 0.20.1, but never got around to upgrading the operating system. Then Zap2It announced they were no longer going to provide data information. A great group of people made a big last minute push to create Schedules Direct as a low cost alternative. The MythTV developers at the same time made a big push to get 0.20.2 out which supported the new Schedules Direct service. Unfortunately, my Fedora Core 4 based system was so old that there were no packages made for it. I tried a couple times to upgrade to Fedora 7 or Fedora Core 6, but always ran into some little issue or another. So I ended up using a slightly modified script I found in the mailing list to allow me to download updated guide data from Schedules Direct but continue to run my old system.

I ran like that until we got a new TV the day after Thanksgiving. The new TV supported High Definition and we discovered that there were a couple stations unencrypted on our basic extended cable (pretty much just the local broadcast stations) available in High Def. So it looked like a good time to rebuild the MythTV box. The new TV also supported VGA in, so I could stop dealing with the shortcomings of the PVR-350‘s TV out. It was a decent little card for doing Standard Def TV, but it wasn’t the best for the Myth menus and the way I had it configured, the only sound I could get to my TV was that from TV shows. I still don’t have the capability to record HD, but at least I have a machine that’s capable.

Now, without further ado, here’s my previous list and my current responses:

  • Channel changing is really slow

This very well may still be an issue…. I’m not sure. I don’t really do the Live TV part of things anymore. Having some idea of how this works (Myth basically first starts a recording then starts watching that recording), I’d say it’s very likely that it does still exist.

  • The fonts in the on screen guide are so small they’re pretty much useless

I guess I don’t know for sure because the guide is really part of Live TV, but I’m pretty sure this would be resolved now. I know when I did my original install, I had to tweak up the font sizes from default to be able to really read some things from across the room. On the new HD TV, the default sizes seem to be great, generally speaking.

  • I still need to figure out how to make channel icons work

As I already mentioned, I solved this one relatively quickly. The procedure is slightly different now than when I did it, but that’s all documented in a post to the MythTV-Users mailing list.

  • My wireless network card is unreliable (it’s an older 802.11b card that sometimes loses connection)

That year (2005) for Christmas, my wife got me an 802.11g linksys wireless card. It doesn’t have native Linux drivers, but it works just fine using ndiswrapper to load the Windows drivers.

  • The On Screen Display and the setup menus often place things off the screen where they aren’t really visible

I didn’t really know all that much about it at the time, but this is due to something called overscan. Basically, CRT based TVs (anything with a tube and a heavy glass front) “project” an image onto the glass screen. Because of differences in the manufacturing process, among other things, the amount of the original picture that lands on the visible area of this glass screen has some variance. My TV had a pretty high level of overscan which meant that most of the things on the edge (whether put there by Myth or by the TV station) didn’t show up. Now that my TV is an LCD TV, I get every pixel that’s sent to it displayed properly, so I no longer get things placed “off the screen.”

  • The sound output from the PVR 350 can only be used for TV sound. Other things that require sound (such as MP3 playback, games, etc) don’t work without a real sound card

I solved this one by no longer using the PVR 350 out as my output (sound or video). I’m now connected to the TV using a VGA cable for video and a standard 1/8″ stereo phone plug for audio. Because of that, MythMusic now works.

  • I only have a 20GB drive for my /video mount so that limits how much stuff I can record

Once again, my wife helped out with this one. She won a contest at work that gave her points she could spend to get, among other things, electronics. She got a 250GB hard drive which I migrated what little videos I had at the time to. No way I could have gone this long with on a 20GB hard drive :). Heck, we keep talking about whether or not to get an even bigger one!

  • It may be that I just haven’t found the module for it, but there’s an FM tuner in the PVR 350 that I don’t seem to have any support for in MythTV

Still haven’t solved this one. Even though I don’t use it for output anymore, I still use my 350 as a tuner.