WFFM. The marmite of Sitecore modules. It’s possibly one of the most commonly used of Sitecore modules but we all love to hate this module. Despite its rough edges, we battle on. I have to admit that I had not used this module in some time; until using it with Sitecore 8 in its MVC guise the last time was over 2 years ago in webforms (ASP.Net, not Sitecore :p).
As improved as it is working with MVC, one thing that frustrated me was creating a bunch of forms only to find that there was a gazillion copies now littered across the site. Why? Because when you add an MVC Form rendering onto the page the only options presented to you is to either create a blank a form or to duplicate an existing one.
Another quick blog post for a fairly minor bug but causes a big annoyance for the content editors.
I tend to use Rendering Parameters a fair amount, it’s a really neat way of making controls more flexible and customisable without duplicating work, making it much easier for editors. But in all versions of Sitecore 8 I have worked with (update 2 to 5) whenever you click “Edit Component Properties” the Control Properties modal opens up correctly but you also jump to the top of the page:
This is such a simple bug that it’s hardly worth a blog post, but something that has been annoying me for some time that finally this week a colleague of mine pointed out the issue. I noticed a few other people suffering from this on screencasts as well.
Well, it seems that it wasn’t so random after all and there was a consistency to when it would appear or not appear…
In a recent question that popped up on Stackoverflow, the user was trying to add some content via the Page Editor, but if the datasource was not set they were using code to create a child item under the current item and set that to the datasource. I suggested setting the
Datasource Location and
Datasource Template fields on the Rendering and just let the user handle the action via the “Select the Associated Content” dialog.
Unfortunately I couldn’t find a good blog post which covered the information I was trying to portray, or my Google skills were lacking a bit. For those seasoned Sitecore developers, this should be pretty second nature, but hopefully useful info for those new to Sitecore and finding their way around.
The following is out-of-the-box functionality, and provides a very user friendly way to add a component to a page and then associate existing or create a new item of a predefined template.