Title: PHP Code in XML import
Last modified: August 21, 2016

---

# PHP Code in XML import

 *  Resolved [dp2web](https://wordpress.org/support/users/dp2web/)
 * (@dp2web)
 * [12 years, 2 months ago](https://wordpress.org/support/topic/php-code-in-xml-import/)
 * How can i put the PHP code which importing XML. I want to show Button1 if user
   is logged in or Button2 if user is not logged in[.](http://dp2web.blogspot.com)
 * Code that i am currently trying on my machine.
 * <?php if ( is_user_logged_in() ) {
    echo ‘<input class=”register” type=”button”
   value=”Register Now” />’; } else { echo ‘<input class=”Apply” type=”button” value
   =”Apply” />’; } ?>
 * [CLick here](http://www.edukart.com/testing/wpress) to view the issue on my website
 * [https://wordpress.org/plugins/wp-all-import/](https://wordpress.org/plugins/wp-all-import/)

The topic ‘PHP Code in XML import’ is closed to new replies.

 * ![](https://ps.w.org/wp-all-import/assets/icon-256x256.png?rev=2570179)
 * [WP All Import – Drag & Drop Import for CSV, XML, Excel & Google Sheets](https://wordpress.org/plugins/wp-all-import/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-all-import/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-all-import/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-all-import/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-all-import/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-all-import/reviews/)

## Tags

 * [login check](https://wordpress.org/support/topic-tag/login-check/)
 * [php code](https://wordpress.org/support/topic-tag/php-code/)

 * 0 replies
 * 1 participant
 * Last reply from: [dp2web](https://wordpress.org/support/users/dp2web/)
 * Last activity: [12 years, 2 months ago](https://wordpress.org/support/topic/php-code-in-xml-import/)
 * Status: resolved