I'm doing migration going to wordpress and needed manual inserting of data to wp_posts table. In inserting the data, I'm using mysql_real_escape_string but html attributes being inserted with additional \" example :
#Original
<img src="imge.jpg" alt="abcde fghij">
#Inserted to wp_posts using mysql_real_escape_string
<img src="\"imge.jpg"\" alt="\"abcde fghij"\">
This is bad and makes the images not working. So I need help of how to insert data to wp_posts.post_content in a way that wordpress acceptable.