Title: Parse error: syntax error, unexpected T_ENDWHILE
Last modified: August 22, 2016

---

# Parse error: syntax error, unexpected T_ENDWHILE

 *  [r1904](https://wordpress.org/support/users/r1904/)
 * (@r1904)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/parse-error-syntax-error-unexpected-t_endwhile-11/)
 * Hey all.
 * Im getting the following error
 * >  Parse error: syntax error, unexpected T_ENDWHILE in /home/###/public_html/###/
   > site/wp-content/themes/Avenue/single-listings.php on line 62
 * Iv changed to names of our site to ###. hope you understand that.
 * The contents of the single-listings.php file are as follows
 * [Large code excerpt removed by moderator per [forum rules](https://codex.wordpress.org/Forum_Welcome#Posting_Code).
   Please use [the pastebin](http://wordpress.pastebin.com/) for all large code 
   excerpts. It works better anyway.]
 * Everything was working fine until about 2 weeks ago… nothings been changed so
   i cant understand the problem. any help would be grateful.
 * Thanks

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

 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/parse-error-syntax-error-unexpected-t_endwhile-11/#post-5698908)
 * Try deactivating all plugins. If that resolves the issue, reactivate each one
   individually until you find the cause.
 * If that does not resolve the issue, try switching to the Twenty Fifteen theme
   to rule-out a theme-specific issue (theme functions can interfere like plugins).
 *  Thread Starter [r1904](https://wordpress.org/support/users/r1904/)
 * (@r1904)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/parse-error-syntax-error-unexpected-t_endwhile-11/#post-5698969)
 * It appears that the problem is coming from the theme.
 * I have been using said theme for a while now with no issues until recently.
 *  Moderator [James Huff](https://wordpress.org/support/users/macmanx/)
 * (@macmanx)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/parse-error-syntax-error-unexpected-t_endwhile-11/#post-5698971)
 * Where did you get the theme from?
 *  Thread Starter [r1904](https://wordpress.org/support/users/r1904/)
 * (@r1904)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/parse-error-syntax-error-unexpected-t_endwhile-11/#post-5699141)
 * it was from themeforest
 *  [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * (@wpyogi)
 * [11 years, 3 months ago](https://wordpress.org/support/topic/parse-error-syntax-error-unexpected-t_endwhile-11/#post-5699142)
 * In that case, you’ll need to ask the developer as we have no way to support commercial
   themes here –
 * [http://codex.wordpress.org/Forum_Welcome#Commercial_Products](http://codex.wordpress.org/Forum_Welcome#Commercial_Products)

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

The topic ‘Parse error: syntax error, unexpected T_ENDWHILE’ is closed to new replies.

## Tags

 * [t_endwhile](https://wordpress.org/support/topic-tag/t_endwhile/)
 * [Unexpected](https://wordpress.org/support/topic-tag/unexpected/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 5 replies
 * 3 participants
 * Last reply from: [WPyogi](https://wordpress.org/support/users/wpyogi/)
 * Last activity: [11 years, 3 months ago](https://wordpress.org/support/topic/parse-error-syntax-error-unexpected-t_endwhile-11/#post-5699142)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
