Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi! :)
Currently i'm developing where i'm using the Umbraco Grid, and i'm using a custom grid render. But i have run into a problem, because i would like the grid to render an "wrap" div if the editor used in the grid isn't an specific type.. :)
I'm using this code
<div class="[email protected] [email protected] column"> <div @RenderElementAttributes(area)> @foreach (var control in area.controls) { if (control != null && control.editor != null && control.editor.view != null) { <text>@Html.Partial("grid/editors/base", (object)control)</text> } } </div> </div>
It's working but i need that wrap div on all it renders except for an editor called "referanceBlock".
I tried and i could see in the JSON that it sees the alias on the editor it renders, i just can't get it to work :/
I would like to have a result like this
<div class="[email protected] [email protected] column"> <div class="content"> //ONLY if it's NOT referanceBlock <div @RenderElementAttributes(area)> @foreach (var control in area.controls) { if (control != null && control.editor != null && control.editor.view != null) { <text>@Html.Partial("grid/editors/base", (object)control)</text> } } </div> </div> // ONLY if it's NOT referanceBlock </div>
Can you guys help me?
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Extending the Umbraco Grid
Hi! :)
Currently i'm developing where i'm using the Umbraco Grid, and i'm using a custom grid render. But i have run into a problem, because i would like the grid to render an "wrap" div if the editor used in the grid isn't an specific type.. :)
I'm using this code
It's working but i need that wrap div on all it renders except for an editor called "referanceBlock".
I tried and i could see in the JSON that it sees the alias on the editor it renders, i just can't get it to work :/
I would like to have a result like this
Can you guys help me?
is working on a reply...