Stand alone
Illustrates how to use SharpTiles without an MVC platform

You can use SharpTiles without the .NET MVC framework. So you can use SharpTiles to generate e-mails, documentation, etc.

You can use a tiles.xml or keep it simple. We will start simple and just call the formatter for a template.
var output = Formatter.FileBasedFormatter("templates/template.txt").
 Format(new Hashtable{{"Key",
  new List{
   new Person{Name="Ruth Kingsley", Age=42},
   new Person{Name="Jacob van Dijk", Age=23},
   new Person{Name="Stuwared Langley", Age=66}
The formatter has some overloads which might suite you. The template looks the same as in the MVC samples.
<fmt:bundle baseName="sample">
  <c:when test="${not fn:empty(Model.Key)}"><fmt:message key="Name"/>,<fmt:message key="Age"/>
<c:forEach items="${Model.Key}"><sharp:include file="row.txt"/>
<fmt:message key="NoData"/>

Other templates are more of the same.

You can also use tiles without the .NET MVC framework. It is a bit more complex.

var configurator = new TileXmlConfigurator("tiles.xml");1
var set = new TilesSet(configurator);2
var model = new TagModel(new Hashtable
   new List
    new Person {Name = "Ruth Kingsley", Age = 42},
    new Person {Name = "Jacob van Dijk", Age = 23},
    new Person {Name = "Stuward Langley", Age = 66}
}).UpdateFactory(new FileLocatorFactory());4
var output = set["template"].Render(model);5

  1. Create a XML based configuration reader
  2. Load all the tiles in the set. (This happens lazily.)
  3. You will have to create a tag model
  4. and you will have to set a factory to load nested templates. Writing this tutorial, I decided to refactor this, so this will be simpeler in the future.
  5. Render the tile.

Contact form fixed

I regret reporting that the contact form was broken for the last week. All mails send to us were corrupted(empty). So reported bugs in the last week are not received. I'm aware that the timing with regards to the monorail release isn't very handy. The contact form is fixed now. I apologize.

4 February, 2010

Monorail released M5

Monorail is released. The release also contains some minor fixes.

23 January, 2010

Monorail almost finished

Maikel Willemse is coding a Monorail view engine. It's available in the nightly release. A tutorial and a new release will be available shortly.

2 January, 2010

No more tiles.xml
(if you like)

A NSTL view engine is now available. You can do SharpTiles without having a tiles.xml. You will lose the power of dependency injection. If you are interested check out the tutorial page.

21 July, 2009

Developer M3 released

Fixed a couple of parse bugs. Cleaned up refreshing of resources, resource locations and registration of the TilesViewEngine. Wrote some tutorials
Ronald Dehuysser contributed the <tiles:insertTemplate/> and <tiles:putAttribute/> tag.

8 June, 2009

HtmlHelper wrapped II

Updated tag reference documentation.

5 April, 2009

Ready for MVC RC 2

SharpTiles is now ready to use with MVC RC 2.

6 March, 2009

HtmlHelper wrapped

The MVC HtmlHelper is now wrapped and can be used. For it's only available in the nightly build. When the documentation and new Tutorials are made a new release will be made.

22 December, 2008

Ready for Beta 1

SharpTiles is now ready to use with MVC Beta 1. The tutorial page will be updated soon.

3 November, 2008

We've got Tiles

It took me a bit longer than expected but Milestone 1 is reached. Tiles are now available.

23 July, 2008

First release

Finally, after some hard work my pet project is ready for its initial release. Here it is! Please give it some thoughts and feel free to add comments.

23 May, 2008

SID: PopUp 0