Title: PHP Error Message
Last modified: August 22, 2016

---

# PHP Error Message

 *  Resolved [Computer Empire](https://wordpress.org/support/users/lighthouseparty123/)
 * (@lighthouseparty123)
 * [11 years, 5 months ago](https://wordpress.org/support/topic/php-error-message-17/)
 * Hi,
 * I have the followed PHP code using your plugin:
 *     ```
       <form id="619843112" method="POST"><select name="selection">
       <option value="Windows 7">Windows 7</option>
       <option value="Windows 8 + 8.1">Windows 8 + 8.1</option>
       </select>
   
       </form>
   
       <!-- PHP TIME -->
   
       [insert_php] //begin script
       $select = $_POST['selection'];
   
       if ($select = "Windows 7") {
       $list = "Text here"
       } elseif ($select ="Windows 8 + 8.1") {
       $list = "Text heree"
       }
       [/insert_php]
   
       <!-- IT'S HTML AGAIN -->
       <p>My Sentence: [insert_php] echo $list; [/insert_php]</p>
       ```
   
 * However, I’m receiving the following message:
 * Parse error: syntax error, unexpected T_VARIABLE in /home/a7707917/public_html/
   wp-content/plugins/insert-php/insert_php.php(48) : eval()’d code on line 2
 * How can I resolve this?
 * [https://wordpress.org/plugins/insert-php/](https://wordpress.org/plugins/insert-php/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * (@willbontrager)
 * [11 years, 5 months ago](https://wordpress.org/support/topic/php-error-message-17/#post-5572311)
 * Try removing `//begin script`
 * Sometimes comments don’t work well in the eval() function (which Insert PHP uses
   to run the PHP code).
 * See [http://www.willmaster.com/software/WPplugins/insert-php-wordpress-plugin-instructions.php#nonworkingelements](http://www.willmaster.com/software/WPplugins/insert-php-wordpress-plugin-instructions.php#nonworkingelements)
   for more important info.
 * Will
 *  Thread Starter [Computer Empire](https://wordpress.org/support/users/lighthouseparty123/)
 * (@lighthouseparty123)
 * [11 years, 5 months ago](https://wordpress.org/support/topic/php-error-message-17/#post-5572314)
 * After doing that, none of the PHP works.
 *  [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * (@willbontrager)
 * [11 years, 5 months ago](https://wordpress.org/support/topic/php-error-message-17/#post-5572315)
 * Computer Empire, try the PHP code on a stand-alone page. You know, with `<?php
   [
   your code here] ?>`
 * When it works on a stand-alone page, it should work in Insert PHP, taking into
   consideration the code elements talked about at the URL posted in my previous
   response.
 * Will
 *  [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * (@willbontrager)
 * [11 years, 5 months ago](https://wordpress.org/support/topic/php-error-message-17/#post-5572381)
 * Gratuitous post in order to mark thread resolved.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘PHP Error Message’ is closed to new replies.

 * ![](https://ps.w.org/insert-php/assets/icon-256x256.gif?rev=3523853)
 * [Woody Code Snippets – Insert PHP, CSS, JS, and Header/Footer Scripts](https://wordpress.org/plugins/insert-php/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/insert-php/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/insert-php/)
 * [Active Topics](https://wordpress.org/support/plugin/insert-php/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/insert-php/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/insert-php/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * Last activity: [11 years, 5 months ago](https://wordpress.org/support/topic/php-error-message-17/#post-5572381)
 * Status: resolved