Note that there are some explanatory texts on larger screens.

plurals
  1. POException:Grails tag [g:applyLayout] was not closed
    text
    copied!<p>I have no clue why this happens.I have a template named _showcontacts.gsp.The source is as follows:</p> <pre><code> &lt;content tag="column1"&gt; &lt;div class="form-edit"&gt; &lt;div class="heading"&gt; &lt;strong&gt; &lt;g:message code="Contact Details of the firm:"/&gt;${name} &lt;/strong&gt; &lt;/div&gt; &lt;div id="hai" class="form-hold"&gt; &lt;form name="company-edit-form" action="save"&gt; &lt;fieldset&gt; &lt;div class="form-columns"&gt; &lt;div class="column" &gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Company Name"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;Company&lt;/content&gt; &lt;g:textField class="field" name="Company" id="Company" /&gt; &lt;/g:applyLayout&gt; &lt;content&gt; &lt;content tag="label"&gt;&lt;g:message code="First Name"/&gt; &lt;textField class="field" name="firstName" id="Company"&gt; &lt;label for="txt1"&gt;&lt;/label&gt; &lt;input type="text" name="txt1" id="txt1" value="${contact.firstName}"&gt; &lt;/textField&gt; &lt;br&gt; &lt;g:message code="Group"/&gt; &lt;textField class="field" name="group" id="Company"&gt; &lt;label for="txt2"&gt;&lt;/label&gt; &lt;input type="text" name="txt2" id="txt2" value="${contact.group}"&gt; &lt;/textField&gt; &lt;br&gt; &lt;g:message code="ID"/&gt; &lt;textField class="field" name="id" id="Company"&gt; &lt;label for="txt3"&gt;&lt;/label&gt; &lt;input type="text" name="txt3" id="txt3" value="${contact.id}"&gt; &lt;/textField&gt; &lt;br&gt; &lt;g:message code="Last Name"/&gt; &lt;textField class="field" name="lastName" id="Company"&gt; &lt;label for="txt4"&gt;&lt;/label&gt; &lt;input type="text" name="txt4" id="txt4" value="${contact.lastName}"&gt; &lt;/textField&gt; &lt;br&gt; &lt;g:message code="Title"/&gt; &lt;textField class="field" name="title" id="Company"&gt; &lt;label for="txt5"&gt;&lt;/label&gt; &lt;input type="text" name="txt5" id="txt5" value="${contact.title}"&gt; &lt;/textField&gt; &lt;/content&gt; &lt;/content&gt; &lt;/div&gt; &lt;/div&gt; &lt;/fieldset&gt; &lt;/form&gt; &lt;/div&gt; &lt;/div&gt; &lt;/content&gt; </code></pre> <p>When executed,it is showing</p> <p>Grails tag [g:applyLayout] was not closed</p> <p>I have rechecked it many times.But my tag is properly closed.What should i do to render this template properly?I also tried converting this template to a view.But same error.I have this applyLayout working properly in another template.I have copied it from there.Don't know why it is not working here. EDIT:Full gsp code which is working: <strong>list.gsp</strong>//view that renders other templates</p> <pre><code>&lt;head&gt; &lt;meta name="layout" content="panels" /&gt; &lt;/head&gt; &lt;body&gt; %{--show all user's details--}% &lt;sec:ifAllGranted roles="MENU_90"&gt; &lt;content tag="column1"&gt; &lt;g:render template="customers" model="[users: users,results:results]"/&gt; &lt;/content&gt; &lt;/sec:ifAllGranted&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p><strong>_Customers.gsp</strong>//template in which applyLayout is working fine</p> <pre><code> &lt;script type="text/javascript"&gt; function asd(tdcId, companyId, companyType,companyName) { alert(companyName); var link = "${g.createLink(controller: 'customer', action: 'showcontacts')}?tdc=" + tdcId + "&amp;companyid=" + companyId + "&amp;companytype=" + companyType+ "&amp;companyname=" + companyName; window.open(link, '', 'width=200,height=100'); } &lt;/script&gt; &lt;div class="form-edit"&gt; &lt;div class="heading"&gt; &lt;strong&gt; &lt;g:message code="Firm Profile"/&gt; &lt;/strong&gt; &lt;/div&gt; &lt;div id="hai" class="form-hold"&gt; &lt;g:form name="company-edit-form" action="save"&gt; &lt;fieldset&gt; &lt;div class="form-columns"&gt; &lt;div class="column"&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Company Name"/&lt;/content&gt; &lt;content tag="label.for"&gt;Company&lt;/content&gt; &lt;g:textField class="field" name="Company" id="Company" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/checkbox"&gt; &lt;content tag="label"&gt;&lt;g:message code="Starts with"/&lt;/content&gt; &lt;content tag="label.for"&gt;Starts with&lt;/content&gt; &lt;g:checkBox class="cb checkbox" name="StartsWith" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Street"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;Street&lt;/content&gt; &lt;g:textField class="field" name="Street" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/checkbox"&gt; &lt;content tag="label"&gt;&lt;g:message code="Starts with"/&lt;/content&gt; &lt;content tag="label.for"&gt;Starts With&lt;/content&gt; &lt;g:checkBox class="cb checkbox" name="StreetStartsWith"/&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Zip code"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;Zip&lt;/content&gt; &lt;g:textField class="field" name="ZipCode"/&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Fagrubrik"/&lt;/content&gt; &lt;content tag="label.for"&gt;Fagrubrik&lt;/content&gt; &lt;g:textField class="field" name="Fagrubrik" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="House no."/&lt;/content&gt; &lt;content tag="label.for"&gt;HouseNo&lt;/content&gt; &lt;g:textField class="field" name="HouseNo" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Tel./Fax."/&lt;/content&gt; &lt;content tag="label.for"&gt;Telephone&lt;/content&gt; &lt;g:textField class="field" name="Telephone" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Company No."/&lt;/content&gt; &lt;content tag="label.for"&gt;CompanyNo&lt;/content&gt; &lt;g:textField class="field" name="CompanyNo" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="City"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;City&lt;/content&gt; &lt;g:textField class="field" name="City" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="TDC ID"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;TdcId&lt;/content&gt; &lt;g:textField class="field" name="TdcId" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Industry Designation"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;Industry Designation&lt;/content&gt; &lt;g:textField class="field" name="IndustryDesignation" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Decision Maker"/&lt;/content&gt; &lt;content tag="label.for"&gt;DecisionMaker&lt;/content&gt; &lt;g:textField class="field" name="DecisionMaker" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="Email"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;Email&lt;/content&gt; &lt;g:textField class="field" name="Email" /&gt; &lt;/g:applyLayout&gt; &lt;g:applyLayout name="form/input"&gt; &lt;content tag="label"&gt;&lt;g:message code="WWW"/&gt;&lt;/content&gt; &lt;content tag="label.for"&gt;WWW&lt;/content&gt; &lt;g:textField class="field" name="WWW"/&gt; &lt;/g:applyLayout&gt; &lt;/div&gt; &lt;/div&gt; &lt;div&gt; &lt;br/&gt;&amp;nbsp; &lt;/div&gt; &lt;/fieldset&gt; &lt;div id="button" class="buttons"&gt; &lt;ul&gt; &lt;li&gt; &lt;g:submitButton id="button" class="buttons" name="Search" value="Search" action="search" style= "background-color:#191DD4 text-color:#FFFFFF"/&gt; &lt;/li&gt; &lt;/ul&gt; &lt;/div&gt; &lt;/g:form&gt; &lt;div class="table-box"&gt; &lt;g:if test="${company}"&gt; &lt;table cellpadding="0" cellspacing="0"&gt; &lt;thead&gt; &lt;tr&gt; &lt;th class="small"&gt;&lt;g:message code="Company Name"/&gt;&lt;/th&gt; &lt;th class="medium"&gt;&lt;g:message code="TDCID"/&gt;&lt;/th&gt; &lt;th class="tiny"&gt;&lt;g:message code="STREET"/&gt;&lt;/th&gt; &lt;/tr&gt; &lt;/thead&gt; &lt;tbody&gt; &lt;g:each in="${company}" status="idx" var="PNo"&gt; &lt;tr&gt; &lt;td&gt; &lt;a href="javascript:void(0)" onClick="javascript:asd('${PNo.tdcId}', '${PNo.companyId}', '${PNo.companyType}', '${PNo.officialName}');"&gt;${PNo.officialName}&lt;/a&gt; &lt;/td&gt; &lt;td&gt; &lt;g:remoteLink action="show" id="${PNo}" before="register(this);" onSuccess="render(data, next);" params="[template:'show']"&gt; ${PNo.tdcId} &lt;/g:remoteLink&gt; &lt;/td&gt; &lt;td&gt; ${PNo.street} &lt;/td&gt; &lt;/tr&gt; &lt;/g:each&gt; &lt;/tbody&gt; &lt;/table&gt; &lt;/g:if&gt; &lt;/div&gt; </code></pre> <p><br> </p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload