0

When submitting a contact form it redirects to a WSOD and this is logged:

Uncaught PHP Exception InvalidArgumentException: "$string ("Message") must be a string." at /Applications/MAMP/htdocs/onb/core/lib/Drupal/Core/StringTranslation/

I've tried creating new forms and setting them as default. It didn't work. I've also tried uninstalling and installing the contact module without much luck. Any thought on how to fix it or dig up what exactly is causing it?

Thanks.

1

You're most likely passing an object or an array to a translation function call. The t() function expects a string as it's first parameter (see the function spec on drupal.org). Search for places where you call the t() function.

More information on how the translation functions are used in D8 can be found on the translation api page on drupal.org. This will give you an idea of how and where you could have translations so you can check those places in your code.

  • I found an old template from a previous bootstrap version in my subtheme. I deleted it and things worked fine. Thanks. – Jed_BH Oct 19 '18 at 14:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.