This control block
<% if $URLSegment='edit' %>
$StudentEdit
<% else_if $URLSegment='add' %>
$StudentAdd
<% end_if %>
is throwing this error.
Parse error: syntax error, unexpected '}' in C:\WINDOWS\Temp\silverstripe-cacheE--websites-_SilverStripe-Reception-Screen.v2.4.0\.cacheE..websites._SilverStripe.Reception-Screen.v2.4.0.themes.J2.templates.Layout.StudentEdit.ss on line 222
Yet went I use the %StudentEdit and $StudentAdd in the same template without the if control all is fine.
Any ideas anyone?