My component has fields like (text,image,componentlinks). I have faced two issues
- since, here we cannot use
<a tridion:href="@fields.internal_link"></a>
, so how can we create a component link using DD4T template? - If some fields left blank it shows an error msg "The given key was not present in the dictionary"
Normally in razor it works fine,but with DD4T its showing me the error
@if(@model.component.fields["quote_text"] != null){
<p>@model.component.fields["quote_text"].Value</p>
}
Did I miss anything or we have some different approach for DD4T?