Use of tags separating Deluge script and html: Script Builder

Use of tags separating Deluge script and html: Script Builder

Hi

I followed the tag explanation given in Create Html Pages
which explains the use of the <% and %> tag to separate the script from the html.  However the example shows the use of the <%}%   as the tag marker with no explanation as to the difference.

I input my script as a free flow. But when I save it, script builder has changed "simplified"  my closing tags. Why?

Original:

html page
<%{%>

.........html script

<%        start my script

%>        end my script tag
<%}%>     close my html script


Script builder change this when saved. The last two lines above are simplified to one line as shown below:

html page
<%{%>

.........html script

<%        start my script

}%>     close my html script


Is there further explanation of the use of these tags as I am getting "null"  error messages even when I think I am using the correct tags (and checking I have closed each one)?


Thanks


Dave