Hi,
I think the confusing thing here is the person answering previously is making the assumption that you have a custom personalisation block on your instance called "toSmartCase" which is likely not available on your installation.
What they have done is created a personalisation block external to the template called "toSmartCase" which contains some custom javascript function .toSmartCase(). They are then asking you to include this and it does not exist.
I have 2 solutions for you and you can test this in any template MKT or RT.
<!-- This section is just to fake up the rtEvent variable as you have documented in your support ticket -->
<%
var rtEvent = <rtEvent><ctx><firstName value="paul sheppard"/></ctx></rtEvent>;
%>
<!--
This section is some javascript to add a <string>.toProperCase() function to all strings in the template.
You can exteneralise this if required, but you would have to add it to a personalition block, and then include it.
I would suggestion for now just to add it to your template.
-->
<%
String.prototype.toProperCase = function() {
var words = this.split(' ');
var results = [];
for (var i = 0; i < words.length; i++) {
var letter = words[i].charAt(0).toUpperCase();
results.push(letter + words[i].slice(1));
}
return results.join(' ');
};
%>
<!-- This first one is a simple version to captialise the first letter of a variable and does not need the toProperCase() function, if this is enough for you, then just use this.-->
<p><%= rtEvent.ctx.firstName.@value.substring(0,1).toUpperCase()+rtEvent.ctx.firstName.@value.substring(1,100).toLowerCase() %></p>
<!-- This second example use the previous toProperCase function and will smart case the whole string -->
<p><%= rtEvent.ctx.firstName.@value.toProperCase() %></p>