Body: <p>I know this is something that has been mentioned a few times but in all instances I've seen, the issue has been fixed in later releases so I'm assuming this is a new problem that has come up.</p>
  
  <p>Using Drupal 7.69 and CiviCRM 5.19.4 on PHP 7.1</p>
  
  <p>When we go into a contact record, relationship and then click on add relationship we get the following error:</p>
  
  <pre><code>Warning: htmlspecialchars() expects parameter 1 to be string, array given in HTML_Common-&gt;_getAttrString() (line 144 of /home/site/public_html/sites/all/modules/civicrm/packages/HTML/Common.php).
  </code></pre>
  
  <p>I cannot replicate this error on the demo site nor other sites we have that are on the same version of CiviCRM and Drupal but I'm hoping this is something someone has come across before and knows an easy fix.</p>
  
  <p>Please let me know if any further information is required and I'll update my question with the relevant information.</p>
  
  <p>Thanks!</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-01-30T15:03:27.530Z
Comments.Text: did you try clearing drupal cache?
Comments.UserDisplayName: Pradeep Nayak
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-01-30T15:11:52.160Z
Comments.Text: I did indeed! And every other kind of cache!
Comments.UserDisplayName: Jade
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-02-04T12:30:28.340Z
Comments.Text: Same warning with CiviCRM 5.21.1 on PHP 7.2
Comments.UserDisplayName: Doka
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-02-04T13:08:12.790Z
Comments.Text: @Doka I've been informed it can relate to custom fields and you have to turn each one off until you find the culprit. Only thing I've really got on it so far
Comments.UserDisplayName: Jade
Tags: <drupal><contacts><error><relationships>
Title: Adding new relationship results in htmlspecialchars warning
ThreadText: # Adding new relationship results in htmlspecialchars warning
  
  (Asked by: username_0 on 2020-01-30)
  
  I know this is something that has been mentioned a few times but in all instances I've seen, the issue has been fixed in later releases so I'm assuming this is a new problem that has come up.
  Using Drupal 7.69 and CiviCRM 5.19.4 on PHP 7.1
  When we go into a contact record, relationship and then click on add relationship we get the following error:
  Warning: htmlspecialchars() expects parameter 1 to be string, array given in HTML_Common->_getAttrString() (line 144 of /home/site/public_html/sites/all/modules/civicrm/packages/HTML/Common.php).
  
  I cannot replicate this error on the demo site nor other sites we have that are on the same version of CiviCRM and Drupal but I'm hoping this is something someone has come across before and knows an easy fix.
  Please let me know if any further information is required and I'll update my question with the relevant information.
  Thanks!
  
  **Tags:** drupal, contacts, error, relationships
  
  > **Comments:**
  > **username_1**: did you try clearing drupal cache?  
  > **username_0**: I did indeed! And every other kind of cache!  
  > **username_2**: Same warning with CiviCRM 5.21.1 on PHP 7.2  
  > **username_0**: @username_2 I've been informed it can relate to custom fields and you have to turn each one off until you find the culprit. Only thing I've really got on it so far  
  
  ---
  
  ## 0 answers
  
  