Posts From February, 2006

2.1 branch svn heads up

I just committed some major changes in svn on the 2.1 branch. You may want to hold off for a couple of days on getting latest. It will build but if you use any skin other than theblues1 it will be broken at run time.

I've been going through all the modules and pages and changing to CSS layout and now I need to go back through the other skins to fix them like I did with theblues1 skin. I should have things in better shape over the next few nights. I was going to wait until it was all working before checking it in but then again I hate to keep this much work checked out and another developer who is doing similar work in the 1.x branch needs to see my work.

Update 2/13/2006: I just commited at least enough fixes that you don't get runtime errors with any of the built in skins. Still the only usable one is theblues1 as the others all need some css work to fix the layout and style. I'll be working on those. If you have your own custom skin, you will need to get the 3 new Panels named divLeft, divCenter, and divRight and add them to your skin and then you will probably have to fix some style to get the layout right. There are some new classes for css, right now theblues1 css has all the right classes, you will need to get the missing ones and add them to your css and probably tweak them to fit your needs.

XHTML and CSS

One of the  great things in 2.0 .NET is that it supports XHTML compliance. For those who don't know XHTML is a newer w3c standard meant to replace HTML and, in a nutshell, is just a stricter version of HTML.

XHTML compliance is really just the first step towards compliance with the w3c Web Content Accessibility Guidelines (WCAG) and the US Government Section 508 guidelines. The big picture goal is to make the web site content accessible to the widest audience of people including those with handicaps that make web browsing difficult by supporting the widest variety of browsers and devices including everything from screen readers to electronic braille pads. The new standards and guidelines are desinged to do just that and I definitely want mojoPortal to comply with these guidelines wherever possible.

The biggest things to be aware of when trying to convert HTML to XHTML are that everything is lower case and eveything must comply with standard xml rules. Some of the HTML tags that did not require formal closing tags now do require them. <BR> for example must be <br /> so that it has and end tag.

The change in 2.0 ASP.NET is that the server controls like TextBox, Calendar, DataGrid, etc render XHTML compliant markup. You still have to make your own markup that wraps these controls compliant.

In mojoPortal I have had the forsight in most places to use <br /> and other XHTML compliant forms even before 2.0 .NET just to be prepared but there are some places where I had non-compliant markup. I am going through all the pages and controls now in the 2.1 branch and fixing these things, its really not that big a job. What is a big job is changing from html table driven layout to using div and span elements with css. This is fairly tedious work for me to go through the whole project and do this and these changes will likely require some effort to convert existing custom skins for those upgrading when I make the next release. if it seems like a lot of work to you just remember I did it for the included skins . When I'm done you should be able to tell what you need to do to upgrade your custom skin by looking at the included layout.Master files and style.css files

At first I thought I would wait and convert to web parts before making this change but I decided to do this first so that I will have cleaner markup when I get to that step. Best to get the skinning and layout really nailed down first. This will be a solid foundation for meeting our compliance goals.

more 2.0 progress and hosting change

I have been making major progress in the 2.1 branch and am happy to report that this site is now running on a build from the 2.1 svn branch and using these new 2.0 .NET features:

  • MasterPages, in place of Paul Wilson's MasterPages we used in 1.x
  • Themes (a very powerfull way to to control the look of server controls) I have put skeleton settings for all the major server controls in the theme.skin files so you can easily see and edit the wide range of properties available for each control.
  • ASP.NET Menu control, you will be able to use this, or TreeView or skmMenu
  • a custom SiteMapProvider
  • some conversion to the new configuration api but still more to convert

After running on mono for over a year, mostly at grokthis.net, it is with mixed feelings that I have moved for the time being back to windows hosting provided by Trendoid Internet Services.

While running this site on mono is a primary goal for the project, running on the latest version of mojoPortal software is even more important and to do that I need a 2.0 .NET environment. This is after all how I do testing, I run it on my sites before I make a release, you know, eating the dogfood and all that. I will be continually testing on mono and as soon as its possible to run with stability on the 2.0 mono stack this site will be moved back to mono hosting.

We will of course continue to support the 1.x branch of mojoPortal for mono users until the 2.0 stack is ready

I've started a page to list hosting companies that are hosting mojoPortal sites
http://www.mojoportal.com/hosting.aspx

I can personally recommend the ones listed there now. If you know of any more that you recommend let me know and I'll add them to the list.

Next up is work on a custom Providers for Personalization and Membership. After those are in place I can start to explore conversion to WebParts

More consistent creation of initial site data

I committed some stuff to svn today that will make it easier going forward to have consistent data initialisation accross the different supported dbs. It will no longer be needed to run the script to create initial site data during installation, only the table creation script and depending on the db maybe a stored procedure script will need to be run.

maintaining the different data creation scripts for each db as new features are added will no longer be needed

I encapsulated the data creation logic up in the business layer in a new class, mojoSetup.cs.

When the application starts it will check the count of rows in the mp_Sites table and if there are 0, it will create the initial site data by calling mojoSetup.CreateInitialData.

If you use the multiple sites on one installation feature of mojoPortal, it will call mojoSetup.CreateNewSiteData whenever you create a new site to populate the new site with the standard pages.

The content for the initial data and new site data comes from new files I added in the /Data/MessageTemplates folder

For example the intial home page content comes from en-US-InitialSiteHomeContent.config

You can localize these by creating your own files with a prefix matching the culture setting you have in the Web.config Culture key and dropping your files in the same folder.

For example a German translation of the same file would be named:
de-DE-InitialSiteHomeContent.config

If it can't find the file for the culture you have set in your Web.config file, it will fall back to using the english file.

As always any contributions of translated files is welcome and many thanks to all those who have contributed the culture files and translations already.