Title: Syntax error, type E_PARSE
Last modified: February 2, 2021

---

# Syntax error, type E_PARSE

 *  Resolved [narmour](https://wordpress.org/support/users/narmour/)
 * (@narmour)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/syntax-error-type-e_parse/)
 * I had added the code give in this post: [https://wordpress.org/support/topic/include-product-notes-in-admin-emails/#post-13925293](https://wordpress.org/support/topic/include-product-notes-in-admin-emails/#post-13925293)
   two weeks ago with no issues, until a week later. WordPress sent an email saying:
 * Your Site is Experiencing a Technical Issue
 * They said the error was caught on this page:
    wp-admin/admin-ajax.php
 * Error Details
    ============= An error of type E_PARSE was caused in line 781 
   of the file functions.php. Error message: syntax error, unexpected ‘&’
 * Line 781 is this section of the code that was provided for adding the purchase
   notes to the admin emails:
 * add_filter (‘woocommerce_email_order_items_args’, ‘send_purchase_note_to_everyone’);
 * I haven’t seen any issues on the site, it seems to be working fine and the admin
   panel is working fine. Is there something I need to change with the code to fix
   this?

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

 *  [Nicola Mustone](https://wordpress.org/support/users/nicolamustone/)
 * (@nicolamustone)
 * Automattic Happiness Engineer
 * [5 years, 4 months ago](https://wordpress.org/support/topic/syntax-error-type-e_parse/#post-13995060)
 * Hello there,
    The error must be coming from something else as the code does not
   have any `&` in it.
 * Checking the script from the link, it looks very straight forward and with no
   errors.
 * Do you have other custom code on your site?
 *  Thread Starter [narmour](https://wordpress.org/support/users/narmour/)
 * (@narmour)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/syntax-error-type-e_parse/#post-13998338)
 * Yes, but there was never any error message till now. This was the only new thing
   added in several months.
 * Why would their error message reference a specific line of code if it’s not where
   the issue is located?
 * I don’t understand why it would even be a week go by with no error and then suddenly
   claim an error.
 *  Plugin Support [Damianne P (a11n)](https://wordpress.org/support/users/drwpcom/)
 * (@drwpcom)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/syntax-error-type-e_parse/#post-14205452)
 * Hi [@narmour](https://wordpress.org/support/users/narmour/). Sorry that we missed
   your last post.
 * Did you check line 781 of functions.php? You can also try adding the code snippet
   to the site using [Code Snippets instead of adding it to functions.php](https://docs.woocommerce.com/document/customizing-woocommerce-best-practices/).
 *  Plugin Support [Damianne P (a11n)](https://wordpress.org/support/users/drwpcom/)
 * (@drwpcom)
 * [5 years, 2 months ago](https://wordpress.org/support/topic/syntax-error-type-e_parse/#post-14257729)
 * Hi [@narmour](https://wordpress.org/support/users/narmour/). We haven’t heard
   from you in a while so I’m going to go ahead and mark this thread as resolved.
   If you still need help with this issue or have any other questions about the 
   WooCommerce plugin, please start a new thread.

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

The topic ‘Syntax error, type E_PARSE’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

 * 4 replies
 * 3 participants
 * Last reply from: [Damianne P (a11n)](https://wordpress.org/support/users/drwpcom/)
 * Last activity: [5 years, 2 months ago](https://wordpress.org/support/topic/syntax-error-type-e_parse/#post-14257729)
 * Status: resolved