datatable retrieving data from json object but not displaying on html table body code example

Example 1: render object id in an array reactjs from database

render() {
    const data =[{"name":"test1"},{"name":"test2"}];
    return (
      <div>
      {data.map(function(d, idx){
         return (<li key={idx}>{d.name}</li>)
       })}
      </div>
    );
  }

Example 2: copied text from internet not inserting in mysql

When I was copying and pasting into textarea it won't allowing me to insert value in database.

Now I found the solution

HTML --- <textarea name="description"></textarea>

PHP --- Please add addslashes like $text = addslashes($_POST['description']);