// Hide a placeholder if it is empty
If Control.controls.count = 0 then
If value.trim.toLower.indexof("[add content here]") > -1 Or StripHTML(HttpUtility.HTMLDecode(value).trim).length = 0 then
Control.visible = false
End If
End If
// Hide a placeholder if it is empty, also adding in a check for images.
If Control.controls.count = 0 then
If value.indexof("<img") = -1 then
If StripHTML(HttpUtility.HTMLDecode(value).trim).length = 0 then
Control.visible = false
Else
If value.trim.toLower.indexof("[add article image here]") > -1 then
Control.visible = false
End If
End If
End If
End If
// Hide another div, if a placeholder is empty
If Control.controls.count = 0 then
If value.trim.toLower.indexof("[add content here]") > -1 Or StripHTML(HttpUtility.HTMLDecode(value).trim).length = 0 then
Div_Id.visible = false
End If
End If
// Add attributes to another div / element based on a placeholder being hidden (e.g. switching a class)
If Control.controls.count = 0 then
If value.trim.toLower.indexof("[add content here]") > -1 Or StripHTML(HttpUtility.HTMLDecode(value).trim).length = 0 then
Control.visible = false
Div_Id.attributes("class")= mainColumn.attributes("class") & " sys_fullWidth"
End If
End If
// Other attribute examples;
Div_Id.attributes("class")= "sys_stickyFace"
Div_Id.attributes("style")= "position:naughty;"