Title: Importing PHP code fails
Last modified: August 20, 2016

---

# Importing PHP code fails

 *  Resolved [OhNoNotHimAgain](https://wordpress.org/support/users/ohnonothimagain/)
 * (@ohnonothimagain)
 * [14 years, 12 months ago](https://wordpress.org/support/topic/importing-php-code-fails/)
 * I have some posts with PHP code embedded which need to be imported. My site uses
   a plugin which enables PHP code execution in the body text of a post. After import,
   the PHP code is mangled and can not be executed. Example:
 *     ```
       <?PHP
       echo "Hello world";
       ?>
       ```
   
 * becomes
 *     ```
       <p><?php<br />
       echo "Hello world";<br />
       ?></p>
       ```
   
 * Any thoughts how to avoid the mangling?
 * BTW, yes, I’m doubling the double quotes in the actual imported .csv file, the
   issue I’m having is not related to that, importing seems to be specifically mangling
   only the PHP portions of the body. Everything else imports perfectly.

The topic ‘Importing PHP code fails’ is closed to new replies.

 * ![](https://ps.w.org/csv-importer/assets/icon-256x256.png?rev=3039593)
 * [CSV Importer](https://wordpress.org/plugins/csv-importer/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/csv-importer/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/csv-importer/)
 * [Active Topics](https://wordpress.org/support/plugin/csv-importer/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/csv-importer/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/csv-importer/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [OhNoNotHimAgain](https://wordpress.org/support/users/ohnonothimagain/)
 * Last activity: [14 years, 12 months ago](https://wordpress.org/support/topic/importing-php-code-fails/)
 * Status: resolved