Darren Ferguon - Weblog
Thursday, July 02, 2009
What kind of UK Umbraco meetup do you want.
If you are interested in attending an Umbraco UK meet up please fill out the following survey. I'll let this survey run for another 5 days and then make the results public in the forum at our.umbraco.org.
I'm not necessarily committing to organise a meet up here, just trying to get a sense for where/when and what should happen according to the UK community.
Saturday, June 27, 2009
A brief summary of Umbraco codegarden 2009
I'm back from Umbraco codegarden 2009 in Copenhagen with the obligatory sunburn. I'm a lot lighter in the wallet but enriched and nourished in terms of ideas and inspiration for web CMS.
As the title says, this is a brief summary. I just sat down and wrote up all of my mental notes from the conference and I realise that I have more to do than I honestly have time for. I've prioritised everything so that the commitments I made in open space sessions are top of the list.
Unfortunately for me Umbraco makes less than 5% of my professional commitments so time is very precious but I've left codegarden this year vowing to increase that 5% because I've realised that I want to work with Umbraco a lot more.
One of the ways to achieve this increase in Umbraco time is commercial packages. I attended an open space session on integrating the three current package repositories - store, our.umbraco and the original package repository - and out of this the minutes show that I have a few actions. First I aim to document some best practices for creating commercial packages and secondly I'll release my framework application that allows you to quickly write some license providers that work with the Umbraco store by implementing some .net interfaces.
Some may argue that by promoting commercial packages I'm not really entering the spirit of the whole Umbraco and open source movement but my answer is simple. If I had an employer subsidising my Umbraco development then everything that I created would be free. Unfortunately that is just not the case. I'll still continue to release free Umbraco packages alongside my commercial offerings.
Continuing my focus on working more with Umbraco I attended open space sessions on Umbraco support and Team development and at other sessions I got the answers from the core team that I needed in order to try and present Umbraco as a viable option for my larger financial services clients.
I've made a commitment to work more with Umbraco this year. I've set myself certain personal goals that I will asses on a regular basis to see if what I am trying to achieve is working.
So that was my personal codegarden experience. Some other highlights for me were:
- Launch of our.umbraco.org proving that Umbraco love their community
- Putting faces to the names of all of those people (let's do a UK meet soon).
- Discovering that I love open space. It isn't just for conference organisers who can't be bothered!
- Great organic lunches and a fantastic venue that encouraged creativity.
A couple of other points from the keynote that I can't really leave out:
- Umbraco 4.1 will be a native .net 3.5 application, with a few interesting new features.
- Umbraco 5 will be a rewrite using asp.net MVC and not backwards compatible with previous releases.
- Umbraco 4.1 will be stable and supported post release of Umbraco 5.
So that was it codegarden. Thanks guys. See you all again next year I hope.
I'm going to get on to my to do list now. Watch this space.
Sunday, June 21, 2009
Extracting document metadata in Umbraco
The screencast below shows some work I've been doing in automatically extracting metadata from documents when they are uploaded to the Umbraco media section.
HINT: You can make the screencast full screen.
Wednesday, June 17, 2009
Things to do in Copenhagen when not attending Codegarden 09
As I'm bringing the family to Codegarden '09 I lazily "crowd sourced" some things for them to do while I am busy geeking it up.
The suggestions that Tommy and Hanako came up with look great so I thought I'd repost them here in case anyone else is spending a couple of extra days in Copenhagen.
First up some suggestions from Tommy:
Guide sites:
http://www.visitcopenhagen.com/tourist (main tourist site when visiting Cph)
http://www.aok.dk/ (unfortunately mostly in Danish - but a main site for testing restaurant, café's etc. The have all sorts of rankings like best value-for-money, best brunch, best gourmet etc. - look in this page for an overview on danish). "AOK anbefaler" means "Recommended by AOK"
Tourist sites:
Canal Tours (nice boat trips in the Copenhagen canals)
Strøget (shopping street, pedestrians only)
Tivoli Gardens (nice and quite old amusement park, also nice at night)
Nyhavn (old houses, restaurants, pubs, old harbor)
Amalienborg (Royal palace)
A lot of the public museums are free, as far as I remember.
Travel Info:
Copenhagen is not really big, so walking around is easy.
Busses/ferry-busses, S-trains and metro is also convenient within
Copenhagen - the same tickets goes for all public transportation.
Consider buying a 10-ticket card or special tourist tickets if you
plan do travel a lot.
Rejseplanen
(travelling I Denmark, including S-train, trains, busses, metro
etc.)
Shopping:
Strøget (great shopping streets, pedestrians only, shopping. Check out the neightboring streets also)
Fields (indoor mall)
Fisketorvet (indoor mall)
Dining:
Generally there is a lot of restaurants around Strøget, Kgs.
Nytorv, St.Kongensgade, Bredgade, Nyhavn. Here's a few
(top-restaurants not included, but I can give a few advices here
also if you are interested). I'm working close to Kgs. Nytorv, so
that's mainly where I use restaurants:
L'Altro (great Italian restaurant, loads of small dishes, a bit
corny interior but great food, reasonable prices)
Oubæk (close to Kgs. Nytorv, great French food, mid-price)
Le Sommelier (well known cph restaurant and wine bar - mid/upper prices)
Zeleste (at Kgs.Nytorv, nice lunch, reasonable prices, small carte)
Wok Shop (at Kgs. Nytorv, great thai food, nice prices)
Perchs Tea Room (tea house)
Nørrebro Bryghus (nice homebrewed beer, food, mid-price)
Next, some suggestions from Hanako:
Some antique shops:
http://www.trianglenantik.dk/index.php?page=1
They have lots of 50s-70s interior and kitchen stuff.
They have very cute toys, cups, furniture etc for kids as well
as stuff for grown ups.
Kids boutique:
http://www.cremedelacremealaedgar.dk/index.php This shop is very famous and popular. The owner buys old textiles from France mainly and remake clothes and accessories with new materials and design. very cute.
Cafes and restaurants:
Riccos is very popular among local people and they do very good
coffee.
http://copenhagen.unlike.net/locations/303344-Ricco-s
Your wife might really like this place: http://www.tea-time.dk/
Very popular restaurant in Vesterbro. http://89.221.175.146/cofoco.php
Their Italian restaurant brunch called Vespa seems also good.
Cafe Hovedtelegrafen . I don't have website link for this cafe. This is at the top of the Post museum? The open sandwiches are very reasonable and you can also enjoy good view.
http://www.madklubben.info/
I found this also in official tourism website.
They say "At Madklubben a three course menu is offered at DKK 200. In July 2008 the people behind the popular restaurant Madklubben opened their second restaurant and named it quite naturally, Den Anden (The Second One). A modern rendition of a Parisian bistro deluxe. "
Restaurant Olsen. One of the most famous restaurants in Copenhagen
apparently.
Ved Stranden 18, 1061 Kobenhavn K
better to book a table at least a day before
tel: 3314-6400
Lunch is from 115dk
3 course dinner is from 295dk
Monday, June 15, 2009
Latest Umbraco version added to my Umbraco trials
I've added Umbraco 4.0.2.1 to my Umbraco trials site. There are 2 distributions, a clean install and one with the latest version of Warren Buckley's CWS website starter package. In the next day or two I'll add a pimped distribution containing all packages from the Umbraco package repository. You can of course Install the packages into the clean distribution should you wish.
For those of you who haven't used my Umbraco trials site, it allows you to create a hosted installation of Umbraco in a single click. There are no limitations on the install, you have full admin access and can install packages as you wish. The trials expire after a short period and are useful for showing someone Umbraco for the first time or evaluating a package that you don't wish to install into your production environment without testing.
The Umbraco trials site has been relatively successful to date serving up more than 300 trials to more than 200 users.
Now, back to trying to prepare some stuff for codegarden. See you all next week.
Thursday, May 28, 2009
Thoughts on Autonomy Interwoven Gearup
Yesterday I attended
Autonomy Interwoven gearup at Claridges in London.
Interwoven were recently
acquired by Autonomy and as an independent Interwoven
consultant with nearly 10 years experience I was keen to learn
about the Autonomy product suite and how their integration into the
Interwoven product suite would affect my day to day work.
An Introduction:
The day was presented in a slick style with an even slicker accompanying audio/visual presentations - I counted six AV technicians seated behind a black screen at the back of the room. The audience was a mix of technical, sales and marketing people from Autonomy Interwoven partners and customers. The tone was very marketing based - the whole day was really about how to to increase revenue through your website using Autonomy products. A large proportion of the audience wanted something different, in an interactive vote at the end of the day 38% of the audience voted that they'd like to see "more technical content" at the next gearup, twice the percentage of any other option.
Throughout the day I felt that the confidence of some of the presenters bordered on arrogance we were told that "Interwoven invented web content management" and there were constant references to Autonomy technology being market leading with "no competitors". Interestingly some of those who had worked with IDOL referred to it as "dated" and "clunky" in private conversations. I'm yet to get my teeth stuck into IDOL personally so I'll reserve judgement but we were consistently told throughout the day what the future of content was and how certain practices were dated. On this subject I feel compelled to make a point.
A little rant:
It is extremely hard to sit and be schooled about the "future" by an organisation whose corporate website and developer support site fail to implement some very basic web standards and best practices. Validating your pages against your declared DTD, Providing RSS Feeds and SEO friendly URLs are just a few extremely basic items that a leading ECM vendor should take the time to implement. Oh, and you can't search the developer site for key TeamSite terminology like DCR, XML and TPL because they are too short. They've been aware of this for years and it never changes.
What I learned:
A few quick bullet points:
- TeamSite 7 and LiveSite 7 to ship this year - focus will be on more IDOL integration.
- LiveSite runtime available for .net platform.
- Autonomy pledged continued support for all Interwoven products (including MetaTagger).
- Autonomy have doubled the number of trained support staff.
IDOL:
We were introduced to IDOL server (Intelligent Data Operating Layer). TeamSite 6.7.2 SP1 ships with IDOL server and from what I understand all content that is entered into TeamSite is also consumed by IDOL via some kind of connector. IDOL is able to analyse unstructured content from a variety of sources - audio, video, email and many more - and "understand" it's meaning. There are lots of technologies in play here - OCR, speech to text, facial recognition to name a few - but the high level concept is that you can throw just about anything at IDOL (with minimal configuration) and it understands.
Let me explain a little about "understands". Like the rest of the day the notion of content being understood was reasonably vague but a lot of emotive language was used. IDOL can gauge sentiment, mood, intimacy and so on. My interpretation is that Autonomy are trying to tell us that their software is smart and it does all of that classification, summarisation, stemming and synonym processing without you having to think. They were also trying to tell us that it does more than that, an example given was how a search for dogs could yield results on Labradors and how IDOL may have a notion that dogs are used by the police. Good stuff maybe, but a bit too high level for my liking.
The demonstrations that we were given were unclear as to how data is retrieved from IDOL though I got the impression that SitePublisher components are shipped with the new version of TeamSite which somehow query the IDOL repository. I was also left unclear as to where IDOL sits within my environment - on the CMS server, in my production environment - and what kind of hardware resources it requires. I'm also wondering where the revenue comes from - If we get IDOL server for free what do we have to buy? Are we getting hooked on this new technology first and the paid for stuff that we can't resist gets brought into play later?
To be honest it was a bit of an information overload with IDOL, we saw it create tag clouds of user sentiment, create user profiling, recognise people words and video and I must admit it left me wanting to try it out. One point of note was that we were shown a scenario where a customer dialling in to a call centre casually mentioned the Chicago cubs and was presented with an application form for a Cubs credit card the next time they visited the company website. This may be fine in the US, I'd be a bit careful about that kind of behaviour in Europe though - perhaps do some reading up ob PHORM.
There was also an impressive demo of MediaBin combined with Autonomy Virage - now one product -which was able to automatically transcribe a video audio track. The demonstration ware pre-recorded. It would have been much more fun to see a video of one the presentations on the day fed into the software so we could see the actual real time results. Text to speech is still far from perfect and audio tracks which aren't clear and regional accents can still confuse the hell out of some systems. If Autonomy wanted to show us how powerful their software was they should have let a member of the audience talk to it.
Integrated Analytics:
Well no, not really. The new version of TeamSite allows you to view some analytical data *if* you are a Webtrends customer. To be honest it wasn't that impressive it was just a bunch of standard Webtrends reports linked to from the contentcenter GUI.
Optimost:
TeamSite 6.7.2 SP1 also has an optional (paid for) component that allows you to test different permutations of a web page in order to determine which was most successful - aka multi-variable testing - success is gauged by the user reaching a 'goal' page on your website. The permutations would be subtle copy or colour changes in your website and you are able to rule out specific permutations to gradually reach the 'winner' page. I wasn't sure about this personally as I didn't like the idea of an ever changing page and how this would affect it's page rank with search engines. There was no demonstration of how the test results are presented and whether it breaks users down by any demographics within the results, but I did speak to a user from British Airways who was very satisfied with the result that Optimost had yielded and he claimed that the optimisations that they had made had easily paid for the software in a very short space of time.
A few moans:
I didn't like the fact that the executive Q&A session wasn't opened up to the floor, we had to provide our questions on paper at the end of the first session and they were vetted over the following hour before the ones which were selected were asked to the company executives on stage. I also thought that each individual presentation could have been opened up to questions at the end, but each presenter finished up exited the stage and the next demonstration video kicked in.
In my opinion they could have easily lost a couple of sessions such as Toby Bell of Gartner, a presentation from Fidelity on how they built their new website and a Q&A on e-commerce with some executives of Autonomy Interwoven customers. I feel that these would have been much better replaced with more audience participation but then again Interwoven have always been quite a closed organisation and I hear that Autonomy are even more so. For the record I thought Toby Bell delivered a good presentation but it didn't relate specifically to any Autonomy Interwoven products.
To Conclude:
All in all it was an interesting day. I'm looking forward to getting my hands on some of the technology that Autonomy are bringing to the Interwoven product suite. Unfortunately some of it will be forever out of my reach as they don't really do evaluations. There is a market for technical workshops where developers like me get our hands on this technology maybe these could run alongside gearup in future.
Claridges is a lovely hotel, lunch was fantastic and it was fun to catch up with some old colleagues, meet some new people and put faces to names of people that I knew by reputation.
I'd love to here some feedback from any other attendees. I'd love to here from Autonomy Interwoven to see whether they think I've been fair with my comments and particularly on whether they plan to address any of the basic issues with their corporate sites - I'm here and very willing to help if you want to be helped!
If what we saw yesterday is true IDOL Social Media Analysis will probably read, classify and derive the meaning and sentiment of my blog post and let someone at Autonomy know about it. For all I know it may even respond automatically!
I'm sure I've missed something, but then a day with so much detail is very difficult to summarise.
Thursday, May 14, 2009
Sometimes I’m mistaken for the son of Alex Ferguson
When I check into a hotel in Asia approximately 1 in 4 times I'm asked if I'm the son of Alex Ferguson. Through gritted teeth, I'll reply that I am the son of Clive Ferguson and a Liverpool supporter as well.
Yesterday this "making assumptions based on having the same name as someone thing" went a little further than the normal polite enquiry at a hotel reception desk. My email inbox contained a message from 7cristiano7.
Hello Sir, My name is and am 16 years old. I live in Liberia. I have three years now trying to get help from people to play football in Europe mainly in England, but so far found no one yet. Sir am kid who sees only football ahead of my life. Knowing that you are a son of Sir Alex, i therfore neel in tears for you to help play football in England. I called you months back to ask for this help but your respond to me like"this is private no. Dont call this line again" made me afraid and i hung up. Sir if you don't really understand what am trying to, please permit me to call you and explain. A lot a people tells me" play football son it is your call".
I did feel a little guilty because as the email suggests I didn't give the kid a chance to speak when he called me a few months back. I assumed that it was another skype call where I'd be told that I'd won the lottery in Nigeria and all I had to do was furnish the caller with my bank details in order to receive riches beyond my wildest dreams.
So any suggestions on how to advise this kid? I composed the following draft which I am yet to send.
You have the wrong person, I am not Sir Alex Ferguson's son. I just have the same name.
Good luck with your football career.
If you are any good, I'd suggest you play for Liverpool.Cheers.
Darren "son of Clive" Ferguson
Wednesday, May 13, 2009
A view on the Autonomy/Interwoven CMS Vendor meme response
In February Kas Thomas blogged A reality checklist for (CMS) vendors which was picked up by Michael Marth at day.com and turned into the CMS Vendor Meme - I guess most of my readers are familiar with the term meme. Over time various ECM vendors were 'tagged' and responded accordingly.
As a long term independent TeamSite consultant I waited for a response from Interwoven which came courtesy of Tom Wentworth's Blog.
All of the blog posts made for interesting reading and Tom's response was open and honest - however all of the viewpoints being blogged were from the vendors themselves and therefore had some obvious bias.
Yesterday I found a blog post from Adrian Mateljan which gave an alternative response to the meme. Adrian answered the meme drawing upon his experience as RedDot CMS developer. I'm unable to work out from Adrian's site whether he has any connections with RedDot or whether his point of view is an independent one but the post inspired me to give some feedback on the Autonomy/Interwoven response.
By way of disclosure I've been working with TeamSite for over 8 years and I have represented Interwoven on client sites in previous years but not for the last couple of years. All of my opinions relate to TeamSite version 6.5 and are not relevant to any of the other diverse range of software that that they vend.
Tom W didn't see fit to score himself on each point as the meme suggested so I'll suggest one where I feel qualified to do so.
1. Our software comes with an installer program.
Yep. GUI and command line versions. Simplicity itself.
My score: 5/5
2. Installing or uninstalling our software does not require a reboot of your machine.
Nope, but like Tom I question how useful this really is. In my experience if you are installing/uninstalling/servive packing and ECM system then you'd expect some downtime.
My score: N/A
3. You can choose your locale and language at install time, and never have to see English again after that.
I'd never tried that before. Simple, as Tom says. I've just learned that French for logout is "Se déconnecter".
One point, if you customise the GUI and add custom menu Items you don't appear to be able to "localise" those. I'm also pretty sure that when you build a data capture template in TeamSite you'd need to create a copy for each locale in order that field names are displayed in the appropriate language. You could workaround this using TeamSite inline callouts in the data capture template but this would mean custom localisation code.
My Score: 3/5
4. Eval versions of the latest edition(s) of our software are always available for download from the company website.
No. This has long been a frustration of mine. Your customer support account allows you to download the products that you are licensed to use from the support website. As an independent consultant there is no way I can try out new products/upgrades and service packs myself in order to recommend them to a client.
My Score: 0/5
5. Our WCM software comes with a fully templated "sample web site" and sample workflows, which work out-of-the-box.
I agree with Tom about the example workflows. They cover some sample scenarios for content publishing/deployment and I have often used them with minimal modification.
I've never used the "Component Guide" that Tom refers to. I'm not sure if it ships with TeamSite or LiveSite there is an example Templating directory which contains a lot of files and documentation but I've never needed them.
My Score: Not qualified to comment!
6. We ship a tutorial.
Absolutely, see above.
7. You can raise a support issue via a button, link, or menu command in our administrative interface.
No, but I don't see the point of this. You go to support.interwoven.com, login and file your issue. As a developer you could customise the TeamSite GUI and add a link to the support site which would satisfy this requirement. From my perspective I wouldn't want end users raising support issues to the vendor as more often than not they won't be able to distinguish between a bug in the product and a bug in our customisation of the product. Normally issues are reported to an internal development team who escalate to the vendor as appropriate.
My Score: N/A
8. All help files and documentation for the product are laid down as part of the install.
As Tom says, "Help files, yes. Documentation, no". The docs are available to download as a single bundle from the support website or can be viewed online.
My Score: N/A
9. We run our entire company website using the latest version of our own WCM products.
Take Tom's word for it.
My Score: 5
10. Our salespeople understand how our products work.
My *very limited* experience of Interwoven sales suggests that they understand the company product suite very well and how each product integrates with the others. They also seem to be a tight-knit company and the communication between sales and engineering seems to work, when there is something they are unsure of they'll go to the right person and get you an answer pretty quickly.
My Score: Not qualified to comment!
11. Our software does what we say it does.
Very general question. I always find the marketing blurb very high level and fluffy, but then it isn't really targeted at me.
My Score: N/A
12. We don't charge extra for our SDK.
No.
My Score: 5/5
13. Our licensing model is simple enough for a 5-year-old to understand.
Agree with Tom "Since when do 5 year olds buy enterprise software?". I don't really get involved pre-sales.
My Score: N/A
14. We have one price sheet for all customers.
Tom says Yes
My Score: 5/5
15. Our top executives are on Skype, Twitter, or some similar channel, and: Feel free to contact them directly at any time.
Not sure I need to get in touch with 'top executives'. I think a better point would be to question whether it is easy to get in touch with the right people easily, e.g. developers able to contact support. I do know that most Interwoven customers have a dedicated account manager who can put them in touch with whoever they need.
Maybe Kas needs to clarify why he is asking this question. It is good to See Tom Wentworth on twitter and blogging regularly. I just wish Interwoven would give a little love to their developer portal which is missing a few very basic features.
My Score: N/A
In conclusion
I hope this made an interesting read an offered an alternative viewpoint on Autonomy/Interwoven's meme response.
Having stated that CMS vendors should "Violate these rules at your own risk" I wish that Kas Thomas could possibly follow up on his original post and let some of us who have been following know why he thought that some of the points that he raised are so important.
9c56d0fcf93175d70e1c9b9d188167cf
Wednesday, April 08, 2009
Tips for easier TeamSite templating development
I’ve worked with Interwoven TeamSite for some time and over the years fellow developers have frequently complained how difficult it is to develop TeamSite presentation templates. I’ve never really seen these issues and I think a lot of it is down to developer laziness.
Logging, error trapping and step by step debugging are all available but some seem to prefer to complain about how tough templates are to debug rather than invest some time and work out how to make their life easier.
Are you sick of this message?
Comment: Could not process template:
/.iwmnt/default/main/my/branch/default/WORKAREA/default/templatedata/category/type/presentation/html.tpl
If so the following post contains some tips on stress free template development.
1. Install TeamSite locally
If your company has a support account with Interwoven get them to obtain you a development license and install TeamSite on your workstation. It doesn’t matter if you install a Windows, Solaris or Linux version locally – any code you write should be cross platform.
The benefit here is much quicker access to log files and code, it will just make your whole development experience quicker.
2. Use XSLT
TeamSite 6.7 supports XSLT and so do earlier versions by using the iwov_xslt tag in your presentation templates.
If you use XSLT for presentation you can copy your TeamSite DCRs locally and run your XSLT transformations against them independently of the TeamSite server. I use jEdit and the XSLT plugin to do this. Once you’ve perfected your XSLT you upload it to your TeamSite server.
You may find that you miss some of the tags and helper functions that standard TeamSite presentation templates provide, but if you do I’d firmly suggest that the logic you are performing would be better placed as either formAPI code or validation rules in your data capture template.
Note: The iwov_xslt tag has some major issues, it doesn’t support UTF-8 and sometimes chops the first line off your output, but any half decent Perl programmer can get under the bonnet and fix these.
3. Make sure your TPL is valid XML
Simple enough right? It never ceases to amaze me when really bright developers ask me to debug their TPL and it contains mismatched tags or illegal characters.
TIP: Rename the TPL with an .xml file extension and drop it into Internet explorer. IE will complain if the TPL is not well formed XML.
You can also validate it against the appropriate DTD which is in iw-home/local/config.
4. Use Logging
By logging I don’t mean this:
open FILE, ">/tmp/debug.txt"; print FILE "debug message"; close FILE;
Use Log4Perl. It is distributed with TeamSite and is a fully featured logging package. Log4Perl is a Log4J clone and offers many powerful features. Covering the use of Log4Perl is way to lengthy for this post, instead check out this excellent article at perl.com.
5. Learn how to use the iwpt_compile.ipl script
Lots of TeamSite developers don’t realise that you can run your page generation from the command line. This will give you a more specific reason as to what is wrong with your presentation template than the standard error message from the GUI.
Run iwpt_compile.ipl in iw-home/bin and you will get the following usage information:
Syntax: iwpt_compile.ipl -v | (Note: command-line options wrapped for readability)
-h |
-pt presentation_file
[-ofile outfile]
[-smartwrite]
[-manifest filename]
[-oprefix basename_prefix]
[-ocode filename.ipl]
[-umask umask (note: UNIX only)]
[tag-specific args (eg: -iw_pt-dcr filename)]
[-oenc output_encoding_name (default: -oenc UTF-8)]
[-osenc os_encoding_name (default: -osenc UTF-8)]
Notes:
o Extensive online HTML-based is available at:
http://support.interwoven.com/library/devel/tst/pt/
and http://<your_local_teamsite_machine>/iw/help/tst/pt/
o For a complete list of available output encodings, type:
iwpt_compile.ipl -h -oenc
o Common tag-specific flags:
-iw_pt-dcr <dcr>
-iw_pt-arg <arg>
-iw_pt-preview
-iw_include-location <dir>
In most scenarios you'll just need to specify the following arguments:
- -iw_pt-dcr
- -iw_include-location
- -pt
- -ocode
-iw_include-location should be the full path of your TeamSite Workarea and -ocode should be the name of an output file to produce.
The output file is actually just a Perl script which will dump the result of your TPL generation to the standard out.
You may get an error executing iwpt_compile.ipl or you may get an error when you run the resulting output file, but either way the message you receive should be more useful than the standard message you get via the GUI.
6. Trap errors with Perl eval
As Java uses try/catch blocks Perl uses eval.
Consider the following Perl:
my $x = 10; my $y = $x/0; print "value of y is $y\n but this will never get printed";
The illegal division by zero causes Perl to throw an error and die. To stop the script from dying we can do the following.
eval {
my $x = 10;
my $y = $x/0;
print "value of y is $y\n";
};
if($@) { print $@; }
print "\nand the script keeps running\n";
If you were to run the above script you'd see that Perl "catches" the error and continues to run. eval Will cope with any problems that your secript may encounter including syntax error and mis-spelling of keywords. Should eval cause the Perl interpreter to throw an error the descriptive error message is stored in the Perl special variable $@.
Finally consider this TPL extract which shows how you can use the Perl eval block in a TeamSite template to figure our why a Perl block is failing
eval {
my $x = 10;
my $y = $x/0;
iwpt_output("value of y is $y\n");
};
if($@) {
iwpt_output($@);
$logger->warn($@);
}
iwpt_output "\nand the script keeps running\n";
From the snippet above you should be able to see how you can quickly add an eval block to a TPL Perl block to determine what is causing it to fail.
7. Use step by step debugging
If you find yourself at this stage it is a sign that your presentation logic is over complicated and you should really take a step back and question what you are doing.
If step by step debugging is the only option for you then here you can run Perl in debug mode by using the –d flag when starting the interpreter.
I’ve met lots of people who believe you can’t step by step debug Perl whereas in reality it is in incredibly simple to do. I use Activestate Komodo IDE to do my step by step debugging, it is a commercial product and reasonably expensive and to be honest I *only* use it for debugging.
A guide on how to set up Komodo for debugging is here.
In Conclusion
So that is all from me for now. I should have written this post years ago. Hopefully with XSLT template support in TeamSite 6.7 legacy Perl presentation templates will start to fade away, but there are so many old school templates out there that we’ll be supporting them for many years to come yet.
If you have any more TeamSite templating hints and tips or think that anything above is unclear or innacurate, please get in touch.
Monday, March 30, 2009
My Thoughts on FOWA Dublin
This post is a little late, I've been upgrading my blog.
A couple of weeks ago I attended the FOWA "show" in Dublin. The use of the word show is from the organisers Carsonified - not myself - and there was definitely a frustrated rock star air to the whole thing. Words/Phrases of the day were "Awesome" and "Kick-Ass" and the fuck count was up in the twenties within the first hour.
The highlights of FOWA for me were as follows:
Being introduced to Balsamiq Mockups an nice little tool for producing wire-frames of web page layouts, though as Elliott Kember points out - in a rather long winded blog post - it can be dangerous in the wrong hands. Business users could suddenly think they are UI designers who can do your job for you.
Simon Willison gave a good presentation on security. He talked about XSS and SQL Injection which we should all know about but also CSRF and Click Jacking. If you aren't familiar with the latter then you should be. In summary, consider the following when developing web applications:
- Don't modify data in get requests.
- Keep Sessions short.
- Don't use a remember me function (either as a user or developer).
- Don't let your pages be loaded into iFrames - use frame busting Javascript.
- Add a hidden field to your forms containing a server generated token which should be validated when a form is processed.
I know I haven't given reasons for the bullet points above, but they should be fairly obvious. Hopefully Simon's talk will appear online somewhere.
Finally, Robin Christopherson of ability net gave a presentation using a screen reader. Interesting points raised were:
- Auto playing media with sound drowns out the voice of a screen reader making it impossible to navigate a page.
- Badly written alt tags really mess up the usability of a page. Despite the fact this is such a well publicised issue massive amounts of developers still don't provide meaningful alt tags.
- The audio equivalent of Captchas are frequently unintelligible, despite offering to provide manual assistance during signup large organisations - including Google - frequently don't.
I'm now committed to never placing a Capctha on any site that I work on in the future.
Other than the above, the conference was largely uninspiring (for me). David Heinemeier Hansson from 37 Signals was entertaining but delivered a motivational speech rather than anything technical. Blaine Cook (of Twitter fame) came frustratingly close to saying something interesting on several occasions but ended up delivering a very high level and fluffy talk on social networking. The guys from Contrast had a good delivery style, but I didn't need to be told that the web is full of conventions and cliches, I work with it every day. I know.
Anyone else who spoke just fell of my radar. That isn't a criticism, maybe I just wasn't the target audience. I know this post may come across as being overly negative but it honestly isn't intended that way. My kind of conference just involves more tech and more innovative cutting edge stuff.
I'd be interested in going to FOWD in London, they have two tracks as opposed to the one offered in Dublin so you can pick and choose your speakers.
So that was my 5 minute summary of FOWA Dublin. There are a load more posts all over the web complaining about the WIFI, coffee and praising/slating various speakers. I've just picked out the bits and pieces that were relevant to me.