You are here

function ds_search_snippet in Display Suite 7

Same name and namespace in other branches
  1. 7.2 modules/ds_search/ds_search.module \ds_search_snippet()

Returns the snippet field.

1 string reference to 'ds_search_snippet'
ds_search_ds_fields_info in modules/ds_search/ds_search.module
Implements hook_ds_fields_info().

File

modules/ds_search/ds_search.module, line 103
Display Suite search.

Code

function ds_search_snippet($field) {

  // Apache Solr
  if (isset($field['entity']->search_snippet)) {
    return $field['entity']->search_snippet;
  }
  elseif (isset($field['entity']->snippet)) {
    return $field['entity']->snippet;
  }
}