Why is "function is_themler_preview" called on frontend ?

Stagger Lee
1818 Posts
Stagger Lee posted this 06 April 2016

Why is "function is_themler_preview" called on frontend ?

It is making conflict with Download Attachments plugin and download file function. Deactivating Themler core plugin helps.

https://wordpress.org/plugins/download-attachments/

Fatal error: Call to undefined function is_themler_preview() in
D:\EasyPHP\eds-www\some-website\wp-content\plugins\themler-core\themler-core.php
on line 22

Why is "function is_themler_preview" called on frontend ? It is making conflict with Download Attachments plugin and download file function. Deactivating Themler core plugin helps. https://wordpress.org/plugins/download-attachments/ > Fatal error: Call to undefined function is_themler_preview() in > D:\EasyPHP\eds-www\some-website\wp-content\plugins\themler-core\themler-core.php > on line 22
Vote to pay developers attention to this features or issue.
6 Comments
Order By: Standard | Newest
Stagger Lee
1818 Posts
Stagger Lee posted this 06 April 2016

Then second bug, much more problematic. Each time saving something in Themler activate Themler core plugin again-
It should be fixed as soon as possible.

Then second bug, much more problematic. Each time saving something in Themler activate Themler core plugin again- It should be fixed as soon as possible.
Support Team
Support Team posted this 11 April 2016

Hello Stagger Lee,
I'm sorry but both issues are not quite clear. Could you please describe them in more details?

regards,
Aileen

Hello Stagger Lee, I'm sorry but both issues are not quite clear. Could you please describe them in more details? regards, Aileen
Stagger Lee
1818 Posts
Stagger Lee posted this 11 April 2016

  1. When plugin from link is installed. All works OK until you try to download attachment from Post. Default theme doesnt make same problem, only TH theme.

    • Go to plugin management in WP.
    • Disable Themler core plugin.
    • Go to the Themler editing screen and click "Save" button.
    • Themler core plugin is enabled again.

It shoull respect User“s choice and not activate Themler core plugin again on each Save.

1. When plugin from link is installed. All works OK until you try to download attachment from Post. Default theme doesnt make same problem, only TH theme. 2. - Go to plugin management in WP. - Disable Themler core plugin. - Go to the Themler editing screen and click "Save" button. - Themler core plugin is enabled again. It shoull respect User´s choice and not activate Themler core plugin again on each Save.
Stagger Lee
1818 Posts
Stagger Lee posted this 11 April 2016

I mean if you call function "is_themler_preview" only in backend this problem is solved. I dont see need for it on frontend.
Dont know now why it makes problems with this plugin. But restricting it to backend seems as quick solution, to not to lose much time on it.

I mean if you call function "is_themler_preview" only in backend this problem is solved. I dont see need for it on frontend. Dont know now why it makes problems with this plugin. But restricting it to backend seems as quick solution, to not to lose much time on it.
Support Team
Support Team posted this 14 April 2016

Hello Stagger Lee,
thank you for details.
I'm passing both issue to developers for review and we'll contact you when solution is available.

regards,
Aileen

Hello Stagger Lee, thank you for details. I'm passing both issue to developers for review and we'll contact you when solution is available. regards, Aileen
Support Team
Support Team posted this 19 April 2016

Hello Stagger Lee,
to make the Download Attachments plugin working please edit the file

\wp-content\plugins\themler-core\themler-core.php

find the code block

require_once 'functions.php';

if (!class_exists('ShortcodesUtility') && !is_themler_preview() && !is_themler_action()) {
    require_once 'shortcodes/shortcodes.php';
}

and replace it with

require_once(dirname(__FILE__) . '/functions.php');

if (!class_exists('ShortcodesUtility') && !is_themler_preview() && !is_themler_action()) {
    require_once(dirname(__FILE__) . '/shortcodes/shortcodes.php');
}

It is temporary solution. Permanent fix will be included into the next Themler update

regards,
Aileen

Hello Stagger Lee, to make the Download Attachments plugin working please edit the file \wp-content\plugins\themler-core\themler-core.php find the code block require_once 'functions.php'; if (!class_exists('ShortcodesUtility') && !is_themler_preview() && !is_themler_action()) { require_once 'shortcodes/shortcodes.php'; } and replace it with require_once(dirname(__FILE__) . '/functions.php'); if (!class_exists('ShortcodesUtility') && !is_themler_preview() && !is_themler_action()) { require_once(dirname(__FILE__) . '/shortcodes/shortcodes.php'); } It is temporary solution. Permanent fix will be included into the next Themler update regards, Aileen
You must log in or register to leave comments