• Resolved Tharkon

    (@tharkon)


    I noticed that filtering by template does not seem to work so I took a dive into the code and I think the following lines mismatching is the cause of the problem:

    ConditionCallbacks line 82: case 'templates':
    Conditions.php line 300: $conditions[ $name . '_template' ] = array(

    Either change templates to template on line 82.
    Or change template to templates on line 300.

    • This topic was modified 6 years, 11 months ago by Tharkon.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Hello @tharkon:

    Unless the developer explicitly provided users with a filter to hook into, there’s no need to hack our plugin code. Besides, the next time that plugin updates, your customizations will be overwritten.

    The better solution to modifying a template within Popup Maker is to register a shortcode with WordPress, pass the shortcode into a standalone plugin, activate the plugin, and then pass the shortcode tag into the Popup Editor. You can modify any shortcode attributes in the editor.

    Please consult the following: https://docs.wppopupmaker.com/article/367-register-a-shortcode-to-run-editor-scripts

    Thread Starter Tharkon

    (@tharkon)

    I am aware that the customizations will be overwritten the next time that the plug-in updates. This is the main reason I have posted this topic so the typo can be fixed in that update.

    I am not trying to modify a template within Popup Maker, I was not even aware that Popup Maker had templates. And your suggestion of adding a shortcode to the content of a popup in the editor has nothing to do with the problem I brought to attention.

    I am also having the same issue as the original post. The plugin is not allowing me to use template conditions. This is very frustrating. The “resolution” above is not relevant to the original question/issue. It should be removed and a proper solution (from the plugin developer) should be added.

    Thread Starter Tharkon

    (@tharkon)

    I am very disappointed that an error as simple as a typo is allowed to cause such serious problems for such a long time even though a step-by-step instruction for the fix has been provided already. I have just been reapplying the fix myself after every update but this should not be necessary.

    Thread Starter Tharkon

    (@tharkon)

    I noticed there has been an update since I last posted but the fix was not included.

    Any news on when this will be fixed?

    It is a simple typo, and I pointed out the exact files and line numbers where the fix should be applied, the total amount of work to fix it is by now probably an order of magnitude less than the time it took people have spent on this forum topic.

    • This reply was modified 6 years, 8 months ago by Tharkon.
    Plugin Author Daniel Iser

    (@danieliser)

    @tharkon – Sorry this is in the latest version that will go out later this week. The issue was never logged into github for some reason.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Template conditions not working’ is closed to new replies.