I have a drupal 9 form. In it I have one field array which is passed to json encode function. One of the element in field array is a HTML field. While I pass this array to json encode, the front tags of this element is vanished somehow.
Here is my code in the left of the picture and output to the right:
-
How can i get the correct json format of this field?
-
Why is the front
is getting vanished after JSON Encode?