Title: Error when enabling plugin
Last modified: October 5, 2020

---

# Error when enabling plugin

 *  Resolved [Shakila5562](https://wordpress.org/support/users/shakila5562/)
 * (@shakila5562)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/error-when-enabling-plugin-3/)
 * Hi,
 * I have been using the plugin for sometime now. However I’m now receiving error
   messages, maybe due to PHP.
 * Warning: Use of undefined constant ATTRB_MARKUP_DESC_END – assumed ‘ATTRB_MARKUP_DESC_END’(
   this will throw an Error in a future version of PHP) in /home/laparisc/public_html/
   wp-content/plugins/markup-by-attribute-for-woocommerce/src/utility/general.php
   on line 72
 * I have the plugin disabled for now.

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

 *  Plugin Author [Mark Tomlinson](https://wordpress.org/support/users/marktomlinson/)
 * (@marktomlinson)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/error-when-enabling-plugin-3/#post-13495459)
 * Thanks for catching that. My PHP is at 7.2.24 and does not throw an error, even
   though I believe it probably should.
 * Without getting too much into the weeds, I was using a constant named ATTRB_MARKUP_DESC_END,
   when I should have used one named ATTRB_MARKUP_END. Long story, but it essentially
   works the same regardless if the constant is spelled correctly or not. The constant
   was coded as a fail-safe, but caused an error of its own in some versions of 
   PHP.
 * I’ve fixed it and will be test and roll out the fix by the end of day.
 * EDIT: Sorry, the reason it didn’t throw an error is because it is in a database
   update routine that only is run once if you are at an old version of the database.
   No wonder it didn’t show up in testing.
    -  This reply was modified 5 years, 8 months ago by [Mark Tomlinson](https://wordpress.org/support/users/marktomlinson/).
 *  Thread Starter [Shakila5562](https://wordpress.org/support/users/shakila5562/)
 * (@shakila5562)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/error-when-enabling-plugin-3/#post-13498380)
 * Hi Mark,
 * Thank you very much for your response and for the update on the plugin. However,
   I am still throwing the errors below. Should I just switch the version of my 
   php?
 * Warning: Use of undefined constant ATTRB_MARKUP_DESC_BEG – assumed ‘ATTRB_MARKUP_DESC_BEG’(
   this will throw an Error in a future version of PHP) in /home/laparisc/public_html/
   wp-content/plugins/markup-by-attribute-for-woocommerce/src/utility/general.php
   on line 73
 * Warning: Use of undefined constant ATTRB_MARKUP_END – assumed ‘ATTRB_MARKUP_END’(
   this will throw an Error in a future version of PHP) in /home/laparisc/public_html/
   wp-content/plugins/markup-by-attribute-for-woocommerce/src/utility/general.php
   on line 73
 * Warning: Cannot modify header information – headers already sent by (output started
   at /home/laparisc/public_html/wp-content/plugins/markup-by-attribute-for-woocommerce/
   src/utility/general.php:72) in /home/laparisc/public_html/wp-includes/functions.
   php on line 6270
 *  Plugin Author [Mark Tomlinson](https://wordpress.org/support/users/marktomlinson/)
 * (@marktomlinson)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/error-when-enabling-plugin-3/#post-13498667)
 * Frustrating.
 * So, I’m consolidating all the definitions of the constants to a single routine,
   right up front. That should take care of it. I’ll have that ready within a few
   hours.
 *  Thread Starter [Shakila5562](https://wordpress.org/support/users/shakila5562/)
 * (@shakila5562)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/error-when-enabling-plugin-3/#post-13498939)
 * Awesome! Thank you!

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

The topic ‘Error when enabling plugin’ is closed to new replies.

 * ![](https://ps.w.org/markup-by-attribute-for-woocommerce/assets/icon-256x256.
   png?rev=2952499)
 * [Markup by Attribute for WooCommerce](https://wordpress.org/plugins/markup-by-attribute-for-woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/markup-by-attribute-for-woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/markup-by-attribute-for-woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/markup-by-attribute-for-woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/markup-by-attribute-for-woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/markup-by-attribute-for-woocommerce/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Shakila5562](https://wordpress.org/support/users/shakila5562/)
 * Last activity: [5 years, 8 months ago](https://wordpress.org/support/topic/error-when-enabling-plugin-3/#post-13498939)
 * Status: resolved