Title: unexpected T_FUNCTION
Last modified: August 21, 2016

---

# unexpected T_FUNCTION

 *  Resolved [SkyRanger](https://wordpress.org/support/users/skyranger/)
 * (@skyranger)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/unexpected-t_function/)
 * Parse error: syntax error, unexpected T_FUNCTION in /home/public_html/wp-content/
   plugins/ngs-sam-integrator/php/widgets.php on line 285
 * Lines 285 – 287
 * add_action( ‘widgets_init’, function() { register_widget(“ngs_top_req_widget”);});
   
   add_action( ‘widgets_init’, function() { register_widget(“ngs_upcoming_tracks_widget”);});
   add_action( ‘widgets_init’, function() { register_widget(“ngs_recently_played_widget”);});
 * [http://wordpress.org/plugins/ngs-sam-integrator/](http://wordpress.org/plugins/ngs-sam-integrator/)

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

 *  Thread Starter [SkyRanger](https://wordpress.org/support/users/skyranger/)
 * (@skyranger)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/unexpected-t_function/#post-4353337)
 * Tried this plugin on another wp site and worked, guess there is a conflict with
   another plugin on my other wp site.
 *  [MisiekM](https://wordpress.org/support/users/misiekm/)
 * (@misiekm)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/unexpected-t_function/#post-4353442)
 * Hi!
    I have a problem with the same. I checked on 3 different systems. I installed
   on a version without plugins, and plugins. There is still a problem.
 *  Plugin Author [Steve Williams](https://wordpress.org/support/users/netguysteve/)
 * (@netguysteve)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/unexpected-t_function/#post-4353456)
 * Okay. I have looked into this a little further for you. This error message is
   usually caused by compatibility with older versions of PHP or, in some cases,
   themes.
 * I have released a fix which should ensure compatibility. The drawback is that
   the functions which initialize the widgets can no longer be cached by WordPress.
   This shouldn’t cause any significant performance impacts to the plug-in or to
   your site, but I wanted to let people know, regardless.
 * The version with the fix is version 1.2.1.

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

The topic ‘unexpected T_FUNCTION’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/ngs-sam-integrator_050505.svg)
 * [NGS SAM Integrator](https://wordpress.org/plugins/ngs-sam-integrator/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/ngs-sam-integrator/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/ngs-sam-integrator/)
 * [Active Topics](https://wordpress.org/support/plugin/ngs-sam-integrator/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/ngs-sam-integrator/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/ngs-sam-integrator/reviews/)

 * 3 replies
 * 3 participants
 * Last reply from: [Steve Williams](https://wordpress.org/support/users/netguysteve/)
 * Last activity: [12 years, 3 months ago](https://wordpress.org/support/topic/unexpected-t_function/#post-4353456)
 * Status: resolved