Title: 0.6.0 beta doesn&#039;t work, unexpected parse error
Last modified: August 21, 2016

---

# 0.6.0 beta doesn't work, unexpected parse error

 *  Resolved [chow0050](https://wordpress.org/support/users/chow0050/)
 * (@chow0050)
 * [12 years ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/)
 * Hi, I encountered an error when I updated:
 * Parse error: syntax error, unexpected T_FUNCTION in …/wp-content/plugins/recipepress-
   reloaded/php/helper/admin_menu_helper.php on line 65
 * Thanks
 * [https://wordpress.org/plugins/recipepress-reloaded/](https://wordpress.org/plugins/recipepress-reloaded/)

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

 *  Plugin Author [Jan Koester](https://wordpress.org/support/users/dasmaeh/)
 * (@dasmaeh)
 * [12 years ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5128979)
 * Please post the PHP version you are using. This sees to be a version specific
   problem.
 * Regards Jan
 *  Thread Starter [chow0050](https://wordpress.org/support/users/chow0050/)
 * (@chow0050)
 * [11 years, 12 months ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5129079)
 * Hi,
 * I’m using 4.1.8. Thanks!
 *  Plugin Author [Jan Koester](https://wordpress.org/support/users/dasmaeh/)
 * (@dasmaeh)
 * [11 years, 12 months ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5129081)
 * All right. The file mentioned in your error contains a function not supported
   by PHP v4. As PHP 4 is end-of-life since 2008 I will not fix this issue. Please
   update to PHP 5.
 * BTW: PHP 4.1.8 is REALLY OLD and has to be considered insecure!
 *  Thread Starter [chow0050](https://wordpress.org/support/users/chow0050/)
 * (@chow0050)
 * [11 years, 12 months ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5129083)
 * Hi sorry, 4.1.8 is the version for myPhpAdmin. My php version is currently 5.2.17.
   Sorry for the wrong information.
 *  Plugin Author [Jan Koester](https://wordpress.org/support/users/dasmaeh/)
 * (@dasmaeh)
 * [11 years, 12 months ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5129085)
 * PHP 5.2.x is not supported any more since January 2011, so you might consider
   to update. Which OS are you using?
 * The bug you mentioned is affecting PHP <= 5.2. I’ll have to think about if and
   how I’m going to fix this.
 *  Plugin Author [Jan Koester](https://wordpress.org/support/users/dasmaeh/)
 * (@dasmaeh)
 * [11 years, 12 months ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5129086)
 * The fix seems to be easy. Could you please try to replace lines 51-68 in php/
   helper/admin_menu_helper.php by the following:
 *     ```
       function f_comment( $entry ){
       	return $entry[0] == T_COMMENT;
       }
       function rpr_admin_template_list()
       {
       	$dirname = WP_PLUGIN_DIR . '/recipepress-reloaded/templates/';
       	$templates = array();
   
       	if ($handle = opendir( $dirname )) {
       		while (false !== ($file = readdir($handle))) {
       			if( $file !='.' && $file !='..' && $file != '.svn' ) {
       				// Param parsing inspired by http://stackoverflow.com/questions/11504541/get-comments-in-a-php-file
       				// put in an extra function?
       				$params=array();
       				$filename = $dirname . $file . '/recipe.php';
   
       				$docComments = array_filter(
       						token_get_all( file_get_contents( $filename ) ),
       						/*function($entry) {
       							return $entry[0] == T_COMMENT;
       						}*/
       						"f_comment"
       				);
       ```
   
 * This should fix the problem. Thanks for testing this for me, as I can’t test 
   the plugin against all available PHP versions.
 * Regards Jan
 *  Thread Starter [chow0050](https://wordpress.org/support/users/chow0050/)
 * (@chow0050)
 * [11 years, 12 months ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5129114)
 * Hi Jan,
 * It worked! Thank you!

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

The topic ‘0.6.0 beta doesn't work, unexpected parse error’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/recipepress-reloaded_c4dbbe.svg)
 * [RecipePress Reloaded](https://wordpress.org/plugins/recipepress-reloaded/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/recipepress-reloaded/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/recipepress-reloaded/)
 * [Active Topics](https://wordpress.org/support/plugin/recipepress-reloaded/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/recipepress-reloaded/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/recipepress-reloaded/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [chow0050](https://wordpress.org/support/users/chow0050/)
 * Last activity: [11 years, 12 months ago](https://wordpress.org/support/topic/060-beta-doesnt-work-unexpected-parse-error/#post-5129114)
 * Status: resolved