Title: Array link fails in INSERT PHP
Last modified: January 1, 2017

---

# Array link fails in INSERT PHP

 *  [hurlburtgf](https://wordpress.org/support/users/hurlburtgf/)
 * (@hurlburtgf)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/array-link-fails-in-insert-php/)
 * I am running a simple while loop in Insert PHP under php 5.6.27.
 * [insert_php]
    $x = 1; while ($x <= 5) { echo $x; $x++; } [/insert_php]
 * This yields a php syntax error: Parse error: syntax error, unexpected ‘;’ in /
   Users/Nonesuch1/Giga/TECH/IOT/nistir/Website/wp-content/plugins/insert-php/insert_php.
   php(48) : eval()’d code on line 3
 * As the syntax is already correct, the error is evidently indicative of something
   else.
 * Looking deeper, with all sorts of debugging enabled, the detail is revealing:
 * # Time Memory Function Location
    1 0.0035 239752 {main}( ) …/index.php:0 2 0.0035
   240224 require( ‘/Users/Nonesuch1/Giga/TECH/IOT/nistir/Website/wp-blog-header.
   php’ ) …/index.php:17 3 0.0847 3171928 require_once( ‘/Users/Nonesuch1/Giga/TECH/
   IOT/nistir/Website/wp-includes/template-loader.php’ ) …/wp-blog-header.php:19
   4 0.0981 3409952 include( ‘/Users/Nonesuch1/Giga/TECH/IOT/nistir/Website/wp-content/
   themes/twentyseventeen/page.php’ ) …/template-loader.php:74 5 0.1722 3777104 
   get_template_part( ) …/page.php:27 6 0.1722 3778024 locate_template( ) …/general-
   template.php:167 7 0.1723 3778208 load_template( ) …/template.php:643 8 0.1723
   3791024 require( ‘/Users/Nonesuch1/Giga/TECH/IOT/nistir/Website/wp-content/themes/
   twentyseventeen/template-parts/page/content-page.php’ ) …/template.php:686 9 
   0.1738 3792376 the_content( ) …/content-page.php:22 10 0.1741 3793600 apply_filters()…/
   post-template.php:240 11 0.1741 3793992 WP_Hook->apply_filters( ) …/plugin.php:
   203 12 0.1743 3797360 call_user_func_array:{/Users/Nonesuch1/Giga/TECH/IOT/nistir/
   Website/wp-includes/class-wp-hook.php:298} ( ) …/class-wp-hook.php:298 13 0.1743
   3797776 will_bontrager_insert_php( ) …/class-wp-hook.php:298
 * It would appear that an array value is being returned (or not) to Insert PHP 
   but it cannot be properly interpreted. I thought it might relate to the WP Loop
   or the theme, but various reconfiguration attempts continue to yield the same
   persistent error. I still suspect some sort of misconfiguration.
 * Quite frustrated well into the second week of troubleshooting.

Viewing 1 replies (of 1 total)

 *  [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * (@willbontrager)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/array-link-fails-in-insert-php/#post-8609817)
 * Unfortunately, I’m unable to duplicate the issue using php 5.6.10 or php 5.3.29,
   both WP 4.7. The code runs like it’s supposed to.
 * I assume you’re using the “Text” tab and not the “Visual” when editing the post
   or page.
 * My thought is that something is modifying the code before Insert PHP has a go
   at it.
 * To test, deactivate any plugins that might conceivably modify the page or post
   content or load it more than once, perhaps for scanning before publishing. Examples
   to test are SEO plugins and wrappers like Visual Composer.
 * Will
    -  This reply was modified 9 years, 3 months ago by [WillBontrager](https://wordpress.org/support/users/willbontrager/).

Viewing 1 replies (of 1 total)

The topic ‘Array link fails in INSERT PHP’ is closed to new replies.

 * ![](https://ps.w.org/insert-php/assets/icon-256x256.gif?rev=3475630)
 * [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/)

 * 1 reply
 * 2 participants
 * Last reply from: [WillBontrager](https://wordpress.org/support/users/willbontrager/)
 * Last activity: [9 years, 3 months ago](https://wordpress.org/support/topic/array-link-fails-in-insert-php/#post-8609817)
 * Status: not resolved