Title: Installation fails with syntax error on line 2872 (wp-includes/function.php)
Last modified: September 1, 2016

---

# Installation fails with syntax error on line 2872 (wp-includes/function.php)

 *  Resolved [aholub](https://wordpress.org/support/users/aholub/)
 * (@aholub)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/installation-fails-with-syntax-error-on-line-2872-wp-includesfunctionphp/)
 * An attempt to run _ [https://…/blog/wp-admin/install.php](https://…/blog/wp-admin/install.php)_
   fails with the error:
 * >  Parse error: syntax error, unexpected ‘{‘ in /nfs/…/blog/wp-includes/functions.
   > php on line 2872
 * I checked the file, and it seems complete, so this is not a partial-download 
   or truncation issue (5278 lines are present, and the file ends with a legitimate
   close brace terminating `mysql_to_rfc3339(...)`. Also, the brace nesting in the
   function that contains line 2872 seems correct.
 * The PHP version is: PHP 5.2.17 (cli) (built: Apr 1 2016 09:14:22)

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

 *  Moderator [t-p](https://wordpress.org/support/users/t-p/)
 * (@t-p)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/installation-fails-with-syntax-error-on-line-2872-wp-includesfunctionphp/#post-7515046)
 * > The PHP version is: PHP 5.2.17
 * Please review: [https://wordpress.org/about/requirements/](https://wordpress.org/about/requirements/)
 *  [Jon Brown](https://wordpress.org/support/users/jb510/)
 * (@jb510)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/installation-fails-with-syntax-error-on-line-2872-wp-includesfunctionphp/#post-7515134)
 * [@tara](https://wordpress.org/support/users/tara/) – 5.2.17 is greater than 5.2.4…
   _requirements_ are different from the recommendations 😉
 * [@aholub](https://wordpress.org/support/users/aholub/) – if you have a you have
   a problem in /wp-includes, the first thing to do is reinstall WordPress Core.
   Odds are though that the unbalance brace may be elsewhere.
 * How did you install WordPress? Have you checked wp-config for syntax errors?
 *  Thread Starter [aholub](https://wordpress.org/support/users/aholub/)
 * (@aholub)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/installation-fails-with-syntax-error-on-line-2872-wp-includesfunctionphp/#post-7515135)
 * I’ve resolved it. Apache was using a different PHP version than the one that 
   was available on the command line. Fixed it in httpd.conf. Thanks, everybody,
   for your help.

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

The topic ‘Installation fails with syntax error on line 2872 (wp-includes/function.
php)’ is closed to new replies.

## Tags

 * [Install](https://wordpress.org/support/topic-tag/install/)
 * [installation](https://wordpress.org/support/topic-tag/installation/)
 * [syntax error](https://wordpress.org/support/topic-tag/syntax-error/)

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 3 replies
 * 3 participants
 * Last reply from: [aholub](https://wordpress.org/support/users/aholub/)
 * Last activity: [9 years, 11 months ago](https://wordpress.org/support/topic/installation-fails-with-syntax-error-on-line-2872-wp-includesfunctionphp/#post-7515135)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
