Example: Embedding a Legacy Form (PS5Forms)

The forms engine from Smartsite 5 still exists in SixSmartsite, but not in the iXperion Publication Engine. To use these forms, an Application page rendered by the CMS Engine is embedded in a page.

The application page could look something like this:

HTML CopyCode image Copy Code
<html>
 <head>
  <title><se property="title" /></title>
  [deferproperty("_headers")]
  <style type="text/css">
   [deferproperty("_css")]
  </style>
  <script type="text/javascript" language="javascript">
   <!--
   [deferproperty("_jsglobals")]
   function doOnload()
   {
    [deferproperty("_jsonload")]
   }
   // -->
  </script>
 </head>
 <body onload="doOnload()">
  <se type="renderform" error="{error}">
   <parameters>
    <formid>1234</formid>
    <feedbackmessage>information received successfully</feedbackmessage>
   </parameters>
  </se>
 </body>
</html>

Includes and other elements in the head section can be passed to the respective placeholders in the embedding page.

Smartsite SXML CopyCode image Copy Code
<se:embeduri location="/cms/smartsite.dws?id=NAWFORM&amp;ch=mgr" 
usepostdata="true"
fixlinks="true"
save="headSection=this.headsection()"
/>

<se:format condition="buffer.get('headSection') != null" inputdata="headSection">
 <se:rowformat expression="this.field('TagName')=='script' AND this.field('URL')!=''">
  {placeholder.addjavascriptinclude(this.field('URL'), ((this.field('Extra')!='') AND (convert.toboolean(string.isempty(this.field('Extra'),'false')))))}
 </se:rowformat>
 <se:rowformat expression="this.field('TagName')=='script' AND this.field('URL')==''">
  {placeholder.addjavascript(this.field('Data'))}
 </se:rowformat>
 <se:rowformat expression="this.field('TagName')=='link' AND this.field('Rel')=='stylesheet'">
  {placeholder.addcssinclude(this.field('URL'), this.field('Extra'))}
 </se:rowformat>
 <se:rowformat expression="this.field('TagName')=='style'">
  {placeholder.addcss(this.field('Data'))}
 </se:rowformat>
</se:format>