Title: Array to string conversion
Last modified: June 7, 2019

---

# Array to string conversion

 *  [Joris Menke](https://wordpress.org/support/users/joris2110/)
 * (@joris2110)
 * [7 years ago](https://wordpress.org/support/topic/array-to-string-conversion-8/)
 * I have setup an search page for a client, but when a keyword brings up a page
   that has anything other than a string it shows the notice array to sting conversion.
   
   [https://pastebin.com/eNM5cWSp](https://pastebin.com/eNM5cWSp) On the results
   page i have excerpts and that is what causes the error. What can i do to maybe
   not shows the excerpts if the page excerpt is anything other than a string?

Viewing 1 replies (of 1 total)

 *  Plugin Author [Mikko Saari](https://wordpress.org/support/users/msaari/)
 * (@msaari)
 * [7 years ago](https://wordpress.org/support/topic/array-to-string-conversion-8/#post-11617304)
 * That’s something to do with your custom fields. Looks like you may have some 
   complicated array structures in your custom fields. Relevanssi should be able
   to handle simple arrays, but multilevel arrays may be problematic. Can you please
   show me an example of what kind of data you have in your custom fields?
 * Relevanssi has a filter `relevanssi_custom_field_value` which filters the custom
   field values before Relevanssi does anything with them, so one solution is to
   add a filter that converts the complicated custom field data to something Relevanssi
   can handle. This same problem is likely happening in indexing, too, so a filter
   like that would help in indexing as well.

Viewing 1 replies (of 1 total)

The topic ‘Array to string conversion’ is closed to new replies.

 * ![](https://ps.w.org/relevanssi/assets/icon-256x256.png?rev=3529670)
 * [Relevanssi - A Better Search](https://wordpress.org/plugins/relevanssi/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/relevanssi/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/relevanssi/)
 * [Active Topics](https://wordpress.org/support/plugin/relevanssi/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/relevanssi/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/relevanssi/reviews/)

## Tags

 * [array](https://wordpress.org/support/topic-tag/array/)
 * [conversion](https://wordpress.org/support/topic-tag/conversion/)
 * [excerpt](https://wordpress.org/support/topic-tag/excerpt/)

 * 1 reply
 * 2 participants
 * Last reply from: [Mikko Saari](https://wordpress.org/support/users/msaari/)
 * Last activity: [7 years ago](https://wordpress.org/support/topic/array-to-string-conversion-8/#post-11617304)
 * Status: not resolved