Greetings @cleanskins77,
A few quick questions would be:
- Is the message configured? Settings → Hide Cart Functions → is there text in the “Custom Message” field for their rule?
- Is the rule disabled? Is the “Disable” checkbox unchecked for that rule?
- Is it product/category specific? If they have products or categories selected, does the product they’re viewing match?
- Logged in status? What’s the “Logged In Users” setting for that rule? The logic skips the message if:
- Set to “logged in” AND user IS logged in
- Set to “logged out” AND user is NOT logged in
The most likely culprit based on the code is the CSS on line 315 that hides .hwcf-ui-custom-message inside .woocommerce-variation-description. If your theme or a WooCommerce update changed how the description is wrapped, the message might be unintentionally hidden.
Did you update your theme and notice this change, or did you see it right after the WordPress 6.9 update? We just updated to version 1.2.10 before seeing your support request. You might try that update first, but I can almost guarantee it won’t fix your issue.
Hi I got it working, not exactly sure how. In the end I got a fatal error so deleted the rule and created a new rule. Now the messages are showing, however the custom message won’t save any link or display colours or different fonts, i.e. I insert the link and change fonts in the custom message and once I save the rule they revert back to plain with no link.
https://charliebeautyco.com.au/product/cleansing-milk-with-dms/
Greetings, @cleanskins77,
I think I found the problem! The sanitization loop iterates over $data (the top-level array with keys like hwcf, edited_hwcf, etc.), but the custom message is stored inside $data['hwcf']['hwcf_custom_message']. The loop checks if $key === 'hwcf_custom_message' but it’s actually checking keys like 'hwcf', 'edited_hwcf', etc.
When $key === 'hwcf' and $value is an array, it runs array_map('sanitize_text_field', $value), which strips all HTML from the custom message field!
Watch for version 1.2.12 as a fix and report back. Please don’t forget to leave a raving review. I don’t make a penny doing this.
great thanks the update fixed it.
Okay great, I will mark this support issue resolved.