@oxiclean – Its not that it doesn’t work well its that its not meant for the use you are trying to use it for.
For example it sounds like where you are trying to add html classes is actually a text string and won’t be rendered as HTML but rather as text.
Thus you can use custom selectors, this mean you don’t have to add anything, no class or html needed.
Instead you use jQuery/CSS selectors. This way you can target any element on the page, whether you can modify its HTML & Class or not.
Example: If your woocommerce outputs html like this for the ? icon.
<div class="woo-product">
...
<p class="more-info"><i class="p-circle"></i> Make It Personal <i class="question-mark"></i></p>
...
</div>
Then for your popup you would use something like .woo-product p.more-info i.question-mark
. Or in english the i tag with class question mark, which resides inside a p tag with more-info class, which resides in the container with class woo-product.
The alternative and how we did it for Easy Modal product pages was like this.
Instead of creating a modal using the editor, you create them in templates using the [modal] or [popup] shortcode.
This example shows how we used it in the loop for blog post.
https://wppopupmaker.com/kb/create-preview-read-popups-posts-inside-loop
This example of course is for a loop, but essentially does the following without further interaction:
- Creates the popups dynamically( on the fly ) for each post.
- Assigns each popup a unique id that includes the POST ID.
- Adds a class to the Post Title Link matching the ID in the shortcode
With that code example, now every post title will open a popup with the contents inside rather than going to a new page.
The same can be done in your case I believe.
Going this route, means you don’t have to maintain multiple modals, they will be created automatically for all new products. The information inside the modal/popup is maintained via the product page instead of elsewhere.
As I said before, there are really multiple ways to accomplish it. Anything this plugin can’t accomplish with its basic usage, it can do with templates & JS.
What you are after can be done without extra maintanance. But it requires using more than the basic functions of the plugin.