December 22nd, 2006 by Adam Najmanowicz | 42 Comments
Just so you know… when you’ll notice a Father Christmas sitting on a chair
in the local mall, it might have never crossed your mind that is’t a hard and
dangerous job of many people that leads to these short moments of joy and
happiness that you and your children experience.
Fortunately the Woodpecker Film has taken
the risk and the courage to document the process for you. But beware!
Precautions must be taken…
December 19th, 2006 by Adam Najmanowicz | 21 Comments
The challenge – The site that we will be coding will have its pages tagged with episerver categories. Implement a control that will list all the pages tagged with a specific category.
The control aspx code seems looks pretty straightforward and is derivative of some other controls that are defined in the EPiServer sample site:
The wirst thing you will notice after looking at the code is that PageList is pretty much a standard ASP.NET reinvented and rehashed. GREAT! Sounds like we can use the Data binding, right? That’s also true:
Does the trick of binding the data to the repeater… uh… oh… sorry… I mean PageList.
Now comes the hard and non-obvious part.
How does one actually find the pages assigned to a category? Short of calling the database directly to query the tblCategorypage table that comes to mind at first, it looks like EPiServer has a really cool page finding module that allows for simple yet fairly effective discovery of pages conforming to some developer defined criteria. Those criteria are defined by means of forming any necessary number of instances of PropertyCriteria class provided as a PropertyCriteriaCollection to Global.EPDataFactory. The result is handed to us back as a PageDataCollection. The fetching of the pages looks like this:
For this to work though, one has to define some more stuff in the web admin part of the site. the usual task is to define the Page Template for the control. In this case when you define the Page Template make sure to put the “AggregatedCategory” property in that should be of type Category selection. This property defines what categories you want your control to aggregate, and you can provide one or more of those. the other property that is required for this very control is “CategoryContainer” of type Page. This is solely for the purpose of having a master page that you define as the “main page” for the chosen category selection. It serves as a clickable header in the control. Unnecessary maybe but one would have to define a caption for the control anyway so why not make it meaningful.
The usage of the said control is trivial. A sample usage on the default EPiServer site looks like this:
*)… couldn’t ressist with the title joke :) For those not in subject… It’s a reference to a silly commercial of one of the market chain (Biedronka) in Poland that advertises recently with “My first *something*… from Biedronka*
The article is based on the knowledge I’ve gathered and work I’ve performed for Cognifide. Cognifide is an official partner EPiServer and the real contributor of the the control.
December 14th, 2006 by Adam Najmanowicz | 9 Comments
EPiServer is an Interesting technology we’ve started working on recently. I will try to blog my impressions and the progress over the course of learning the solution.
Since I just seem unable to learn by reading docs I chose to build an email obfuscating (antispam) control and a paged search as an exercise and a way to learn the guts of the EPiServer.
A couple of loose thoughts for a start…
Translation
I am not sure I fully appreciate the way the translation is performed for the parts of the system that is editor independent . The translation is done by means of xml files stored on the disk in the /lang folder.
Basically what that means is that it’s much more prone to missing translations and thus is not as translation friendly as it could fairly easily be.
For the content I can always fall back to the e.g. english version and look what’s the original value there. not so much for the framework translations. Is there a tool for that? I will investigate that later as we’ll probably want to create a number of controls for the website we’ll be working on soon, and that will need to be translated to many languages. And not just that but also the original template files – we will need much more than what’s available originally in EPiServer.
in which you defined where the translation is to come from. (In this case the path is: “/templates/emailobfuscator/obfuscate”) you need to edito the template framework file and add the translation there with the XPath defined in the control. Which looks along the lines of:
The most annoying part of it though is that it needs to be done for alll the languages if you want the site to be fully translated, which without a tool is not fun.
I will look more into that later. One would expect that a tool like that may exist already.
Technology
I am really looking forward to EPiServer 5.x to be released. It’s to be based on ASP.NET 2.0 which most probably means (I hope)that a number of EPiServer specific technologies will be replaced by a .Net generic technologies. As the ElektroPost notices:
EPiServer Content Framework Is Not Unlike ASP.NET 2.0 Master Pages and Content Pages.
Also the EPiServer seems to be really hard to develop for in VS.Net 2005. I still didn’t Indeed ElektroPost suggests VS 2003 as the development platform, but once switched to 2005 I personally can’t deal with VS 2003 any longer.
The good news though is that it is compatible with .Net 2.0 in a way that you can simply add an ASP 2.0 control and with just slight modifications work with it. You can also use .Net 2.0 partial classes – which means much cleaner code.
Overall the EPiServer is a really positive experience. I’m looking forward to work more with it.
The article is based on the knowledge I’ve gathered and work I’ve performed for Cognifide. Cognifide is an official partner EPiServer and the real contributor of the the control.
December 12th, 2006 by Adam Najmanowicz | 3 Comments
Most of us here use Pandora for the listening to the music with their headphones.
The keyboards we have at the office do not have any sound volume adjusting keys.
It’s mildly annoying that you need to take off your headphones every time someone talks to you or click the system tray every time the musinc is too quiet or too loud. But hey! What do we have CodeProject and Visual Studio for?
December 8th, 2006 by Adam Najmanowicz | 9 Comments
I’ve done some research about Visual studio plugins recently, just so that I can close the tabs and move on here are some links that I cound to contain some useful information: