March 17, 2009

HTML/CSS-Only Data Pager Control

After reading these two articles I thought it would be interesting to see if I could this technique to create a HTML/CSS-only (i.e. no background images) data pager control. Here are some screen shots of what I came up with (the second and third screen shots show the roll-over states) … You can check out the live demo here.  I tried it in the major browsers (FF, Opera, IE7, Safari and Chrome) and it worked great.  Unfortunately it looks like crap in IE6 … If you didn’t know it was possible to render angled shapes using straight HTML/CSS - I recommend checking out the following articles … Using borders to produce angled shapes A Study of Regular Polygons   That’s it.  Enjoy!...

March 05, 2009

.Net Developer Survey - Results

I just closed the survey a few hours ago.  Below is a quick break-down of the results.  I plan on digging into the numbers a little bit further, but at first glance the following responses surprised me … 71.5% of responses indicated they don’t see a problem with blogging while at work.  That seemed incredibly high to me.  I would have guessed the yes/no percentages would have been flipped.  I think every boss I have ever had would have fired me on the spot if they caught me blogging at work.        45.31% of responses indicated they don’t use social bookmarking sites.  That seemed a little low. Over 75% of the responses indicated they have been at their current job for 4 years or less. I am not surprised by this, but I still think this is really high (or wish it would be lower).    Twice as many people use linkedin...

Topics: Other

March 02, 2009

.Net Developer Survey

So I recently switched jobs (again!).  And during my time off, I had an interesting conversation with a couple of colleague’s about how ‘internet social’ the average developer is and if that has anything to do with their productivity.  Our opinions varied so I thought I would ask for some help.  I came up with a survey that captures the essence of our conversation.  If you can spare a few seconds, here is the link to where you can take it –> survey. I’ll post the results in a few days … Update 3/3/2009: Getting a lot of responses (~400 completed surveys so far) – so thanks everyone.  Also, if you don’t feel like answering a question, or if it doesn’t apply, you can skip the question by clicking the next button.  Update 3/5/2009: I have received about 1,000 responses so I have decided to close the survey.  Checkout the...

Topics: Other

February 15, 2009

Is your employer OK with you keeping an up to date profile on Monster.com?

Since leaving college, I have always been pretty good at keeping my resume up to date.  This actually surprises me because I am typically prone to procrastinate on these administrative types of tasks.  But early on in my career I got in the habit of updating my resume every time I felt I reached some sort of milestone (stuff like getting a promotion, learning new technologies, annual review, etc …). I keep 2 copies of my resume.  A ‘master’ copy that I just keep adding things to (currently 8 pages), and a shorter version (2 pages) that I am continually adding and removing things from.  The short version is what I end up putting on Monster.com, Linkedin.com, and submit when applying for a job. So why am I writing about any of this?  Well, keeping my Monster and Linkedin profiles up to date was a serious point of conflict with...

Topics: Other

February 05, 2009

.NET GoogleReader API

I received some emails last night requesting the source for the console app (download here) that I am using to extract my feeds from google reader, so I figured I would write a quick post about it.  Just to be clear, as far as I know the API is still unofficial and I have no idea when or if google plans on making it public.  So it goes without saying that it could go away, or change dramatically at anytime.  But if you are still interested, here is what you need to know. The best resources I could find on how the API works are pyrfeed Google Reader API Also, there is a project setup on codeplex that is similar to what I have done.  It wasn’t exactly what I was looking for, so I passed it up, but you might also find that helpful as well. Google’s API works...

Topics: Other , Prototype

February 04, 2009

ASP.NET MVC, GoogleReader's Unofficial API and PostRank.com == TheDotNetDaily.com

I had some spare time this past week so I thought it might be a good time to finally take a look at asp.net's new mvc framework.  My plan was to start out by building a very simple application that I could add features to slowly over time.  I figure I will start out with a handful of read-only screens and then as I learn more about mvc and gain confidence, I could start looking at some of the more advanced/complicated stuff.  Just sort-of start out slow with some of the basic stuff and go from there. The app I decided to build is going to allow me to browse the feeds I have subscribed to in google reader.  I have more feeds that I can keep up with, so I plan on running each feeds individual posts through a ranking service and using the my new asp.net mvc...

Topics: ASP.NET , Prototype

November 05, 2008

Incentives, Cheating Teachers and Suspicious DNK Accounts

Last week Steve Levitt was in Jacksonville and did a lecture of sorts at a local university.  It was really good and like his Freakonomics book, pretty darn thought provoking.  Steve's lecture consisted mostly of him telling really interesting stories, stopping to point out some of the economic principles along the way.  He only briefly touched on it in the lecture, but his book has a chapter where he talks about a group of teachers that were caught cheating in the Chicago's public school system.  Here is the abstract for a paper Steve published on the subject ... We develop an algorithm for detecting teacher cheating that combines information on unexpected test score fluctuations and suspicious patterns of answers for students in a classroom. Using data from the Chicago Public Schools, we estimate that serious cases of teacher or administrator cheating on standardized tests occur in a minimum of 4-5...

Topics: Other

October 26, 2008

iTunes Data Grid Skin

I am playing around with a couple new data grid skins roughly based on what iTunes looks on my Vista box.  Here is how it is looking so far ... iTunes on Vista ...    My iTunes data grid ... Live Demo | Download   Blue and Gray Skins I actually created 2 slightly different skins- a blue and a gray one.  The gray one is above and is a little bit darker.  The blue one is slightly softer and looks like this ...    The Markup The markup for the grid consists of a HTML table with wrapped in a DIV.  I am using the odd/even classes for zebra striping and I also have a DIV above the TABLE for the title bar.  1: <div class="grid"> 2: <!-- title bar ... --> 3: <div class="title">The title goes here</div> 4: <table class="datatable" cellpadding="0" cellspacing="0"> 5: <thead> 6: <!-- header row...

Topics: ASP.NET , jQuery

October 20, 2008

Hiring and The Google Background Check

Stephen Wynkoop posted an interesting question regarding social networks last week on sswug.org.  Basically he is curious if people are using social networking sites to help make hiring decisions.  Here is what he had to say ... I had an interesting question posed today.  The gist of it was that someone was interviewing to fill a DBA position in their company.  One of the interviewees had been doing DBA work for quite some time and seemed like an interesting candidate.  The issue was that searching for this person online resulted in... nothing.  Nothing at all.  No social sites, no posts, no nothing.  Now, it's possible that it was just necessary to keep searching, but it brought up an intriguing question.  If you cannot find someone online - someone that has been working with computers - is this an issue?  If you couldn't find a single post, a single message, a...

Topics: Other

October 18, 2008

Updates to my Live Traffic Page

I made a few more modifications to the Live Traffic page I posted about previously.  Here is what I changed ... New IP to Location Database I replaced the WIPmainia database with the GeoLite City one that Richard Lawley recommended.  For some IP's it can potentially provide location information down to Region/City/Postal Code level (and its still free).  teebot raised a good question about the accuracy of these free IP to Location databases.  The GeoLite web site claims it's database is over 99.3% accurate on a country level and 76% on a city level for the US.  Not too bad ...      Using ASP.NET to Simulate a Windows Service Decoding an IP address to a location isn't an instantaneous operation.  And I have a feeling as I build out the rest dimensions for my Visit/PageView cube it would be nice to run some of the data scrubbing processes some where...

Topics: Other , jQuery

October 12, 2008

Creating a Live Traffic Page from my PageView/Visit Database

I put a screen on top of the pageview data that I recently started collecting.  Thought I would pass along some of the interesting stuff I encountered while building it ... I used the jQuery jTemplate plug-in Dave Ward blogged about to build the rows for the grid.  The data is fetched from a webservice and then sent through the jTemplate templating engine to build the markup for the rows I looked into finding a free IP to Location database that I could bounce incoming IPs against to get some high level geographic information about my visitors (I need something like this anyway for my PageView/Visit cube) Below is what the end product looks like (you can check out the live version here).  And below the screen shot is some additional information regarding the two points above.   Using jTemplate and a Webservice to Populate the Grid I used jQuery's...

Topics: Other , jQuery

October 07, 2008

v0.2 of my Visit/PageView Cube - Creating a Hierarchy for the Source Dimension

So I am still playing around with building an Analysis Services cube from the pageview data I recently started collecting.  Over this past weekend I added a hierarchy to the Source dimension of my cube that gives me a bit more insight about how visitors find their way to my site.  If you read my last post, you saw that I could view my pageview data broken down by two pretty general traffic sources: direct traffic and referring links ...   Well, now with my new hierarchy, I can not only view hit counts by direct traffic, referring site, or search engine ... ... but I can also drill into each of these sources and view my pageviews at a more granular level. I can do this because I have added a bit of preprocessing logic to my cube creation process that sends all referring urls through a very simple...

Topics: Other

September 29, 2008

v0.1 of my Visit/PageView Analysis Services Cube

So I created a cube using my the visit/pageview that I recently started collecting.  The cube is VERY simple - only 4 dimensions {App, Page, Source, Time} and just a single measure - {Hit}.  I created the cube using the 2005 versions of Visual Studio and Microsoft's Analysis Services.  The IDE's wizards pretty much walk you through the process, which is great because creating an Analysis Services project from scratch is more than a little intimidating.  Especially if your a web developer like me and you don't know a whole lot about querying, let alone designing a cube. Anyway, like I said, my cube is very simple.  The App dimension only contains 2 members: 'mattberseth' for this site, and 'mattberseth2' for my live demo site.  The Page dimension contains all of the unique URLs for both sites as its members, the Source dimension is essentially a bit field for determining...

Topics: Other

September 25, 2008

Maintaining my own Pageview/Visit Database

I have started maintaining my own pageview/visit database for both mattberseth.com (this blog) and mattberseth2.com (my demo site).   Why? I currently use Google Analytics (GA) and I really like it.  But ... You can't (yet) export your raw visit data from GA You can't (yet) browse your GA cube I have other data in my MoveableType database (post dates, categories, commentors, tracebacks, etc...) that GA just doesn't know about.  This information would be interesting to get into the cube.   What have I done so far? Added a small bit of JavaScript to the pages I want to track on on both mattberseth.com and mattberseth2.com.  The script extracts the pages referrer and a few other tokens and sends them a HttpHandler that I have setup on mattberseth2.com (hosted by DiscountASP).  Here is a sample of what is the request/response looks like. The handler extracts the tokens and any http...

Topics: Other

September 21, 2008

Dynamic Data Demos Now Available

Last week DiscountASP upgraded to .Net 3.5 SP1 - so I took sometime this weekend to publish demo's for my 5 Dynamic Data posts.  Here is a quick summary of what is out there ...    ASP.NET Dynamic Data - Simple 5 Table Northwind Example Very simple DD site based on the 5 core Northwind tables.  Read more ... Download | Live Demo   Dynamic Data and Custom Metadata Providers DD enabled controls take rendering hints from the metadata you apply to your data model.  This post shows how you can create a custom metadata provider that will provide sensible default values for the DisplayName and DisplayFormat attributes.  Read more ... Download | Live Demo   A Dynamic Menu For Your Dynamic Data This post continues the custom metadata theme and shows how you can use the existing Category attribute to create a 2 level navigation bar.  Read more ......

Topics: ASP.NET , Dynamic Data

September 15, 2008

Dynamic Data - Experimenting with YUI's DataTable and DataSource Controls

I spent a few hours putting together a Dynamic Data web site using the YUI DataTable and DataSource components.  I mostly just did this out of curiosity to see how easy or difficult it would be to use the DD API with other components besides the GridView and DetailsView controls.  So I created a DD web site that provides read-only access to Northwind's Customer, Employee and Supplier tables, but I am not using ASP.NET's GridView, DataSource and UpdatePanel controls to render the grid.  Instead I have replaced these components with YUI's client side DataTable and DataSource and serve the data using a web service (paging included!).  Below are a few of the highlights, and don't forget to download the sample and try it out for yourself.  Its experimental, but if you are new to DD or YUI you might find it interesting.  [Update: 9/21/2008]: Added live demo link  Download |...

Topics: ASP.NET , Dynamic Data

September 07, 2008

Dynamic Data - Customizing the Delete Confirmation Dialog

I spent some time customizing the delete confirmation dialog in the Dynamic Data site I have been blogging about recently.  Specifically, I looked at ... replacing the browsers default confirm dialog with a jquery thickbox displaying a confirmation message that includes contextual information regarding the row being deleted Below is a screen shot showing how it turned out.  You can read on for the details, or you can download the site and browse the code for yourself.  Hopefully DiscountASP will get upgraded to .Net 3.5 SP1 soon so I can get back to providing demos as well ... [Update: 9/21/2008]: Added live demo link   Download | Live Demo   The Default Confirmation Dialog If you use the Dynamic Data Web Site template to create your DD web site, the List.aspx page template will already include a default delete confirmation dialog that uses the browsers confirm dialog to prompt the user...

August 27, 2008

A Dynamic Menu For Your Dynamic Data

So I am still playing around with building a Northwind Dynamic Data web site.  Tonight I thought it would be interesting to see what it would take to create a menu for navigating the tables in the site.  I was particularly interested in seeing if I could get some grouping or categorization to the metadata so I could create a multi-leveled menu.  It turns out it wasn't too difficult at all (see the screen shot below - the menu is on the left).  I have my tables organized into 4 categories: Sales, People, Products and Reports.  And the cool thing is that this menu is completely dynamic.  You can add, remove or reorganize the categories without touching the UI.  And depending where you are keeping your metadata you could even do this without recompiling your app.  The grouping is automatically discovered from the metadata and the menu is built solely...

Topics: ASP.NET , Dynamic Data

August 24, 2008

Dynamic Data and Custom Metadata Providers

In my previous post on Dynamic Data, I mentioned that you can use the MetadataType attribute to point Dynamic Data at class that contains additional metadata for your model.  This additional metadata will give you more control over how your UI elements render.  If you don't want a column to display in your GridView, want to change the column header text from EmployeeID to Employee ID or want the cell values formatted a little differently this metadata class is where this information gets specified.  The code snippet below shows how this class can be used for customization. [Update: 9/21/2008]: Added link to live demo Download | Live Demo 1: // Attach the Employee Metadata to the Employee 2: // entity that the LINQ to SQL designer generates 3: [MetadataType(typeof(EmployeeMetadata))] 4: public partial class Employee 5: { 6: } 7:  8: // Attach some additional metadata 9: public class EmployeeMetadata 10:...

Topics: ASP.NET , Dynamic Data

August 21, 2008

ASP.NET Dynamic Data - Simple 5 Table Northwind Example

I have been anxiously awaiting the Dynamic Data release.  And now that it is here (it was released with VS 2008 and .Net 3.5 SP1) I decided I would start getting a feel for what is has to offer by building a real simple Dynamic Data web site that allows you to browse the 5 core Northwind tables - Customers, Employees, Orders, Products and Suppliers.  Read on for the details and don't forget to download the code.  DiscountASP hasn't quite upgraded to SP1 so I don't have a live demo setup.  Hopefully they will get the upgrade completed soon, but I made sure to include lots of screen shots so you can get a good idea of what the screens look like.  [Update 9/21/2008] : Add link to the live demo Download | Live Demo   What is Dynamic Data? I try to keep a close eye on ASP.NET, but...

Topics: ASP.NET , Dynamic Data


Consulting Services

Yep - I also offer consulting services. And heck, I'll do just about anything. If you enjoy my blog just drop me an email describing the work you need done.

Recent Comments

  • TimothyP wrote: I work with tons of developers who haven't even got a clue what Twitter of Facebook is. In fact, it'...
  • Janko wrote: Yes it's strange that people think it's ok to blog at work but consider unethical to use facebook. P...
  • Kam Lagan wrote: Hi Matt, The numbers do seem a little "off" to what you perceived the community would be like. But...
  • Siderite wrote: You're kidding me! So the people that don't blog think it is ok to blog at work (maybe because they ...
  • Guy Harwood wrote: Good to see the results. one typo.... 'What best describes your current job title?' appears twice,...
  • sirrocco wrote: One problem with : DEV I DEV II DEV III was that I didn't know what it meant :( .(is it common ...
  • Jack wrote: How many person fill the survery? Blog is very common, so I don't think 71.5% is high. Maybe our bos...
  • Andy wrote: Done. The developer1, developer2 question - not sure how meaningful the results are going to be for ...