WordPress.org

Support

Support » Plugins and Hacks » Device Theme Switcher » [Resolved] [Plugin: Device Theme Switcher] Undefined Function

[Resolved] [Plugin: Device Theme Switcher] Undefined Function

  • Just updated from version 1.5 to 1.6 and I am receiving this error upon viewing on a mobile device:

    Fatal error: Call to undefined function wp_get themes() in/var/www/domains/jhfnstaging.com/wp-content/plugins/device-theme-switcher/dts_class_switcher.php online 14

    I am assuming it is because I am running wp 3.2 although the plugin page says it supports 3+.

    http://wordpress.org/extend/plugins/device-theme-switcher/

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author James Mehorter

    @jamesmehorter

    Hi Aaron,

    I’ll need to release a new version to correct this, thank you for brining it to my attention.

    If you update to WordPress 3.4 the plugin will work correctly. The wp_get_themes() and wp_get_theme() are new to 3.4, so I need to make sure DTS is backwards compatible.

    James

    yes im having the same problem… i changed the wp_get_themes() portion through out your code to get_themes() but the themes are blank where i have to select them in the admin side. i dont want to update to 3.4 because it will break my site. Is there a quick fix?

    Plugin Author James Mehorter

    @jamesmehorter

    dionte247,

    Apologies for the issue you’re running into. DTS is due for a new version release in the coming weeks that will correct this. Ultimately, you should never hack the core of a plugin, because you’ve introduced a php error (That’s what the blank page is).

    Please use version 1.5 for now if you’re unable to update to WordPress 3.4. You can get it here.

    I would also say, if 3.4 ‘breaks your site’ you should correct those issues. The WordPress updates should never break anything unless you’ve hacked the core.

    James

    That didnt work either. Im using WP 3.1 btw,

    The fields in the drop down are blank when i goto the admin section to select the themes i want for hand held and tablet

    Plugin Author James Mehorter

    @jamesmehorter

    Hi Aaron & dionte247,

    We’ve released a new version of DTS (v1.7) that is completely backwards compatible for WordPress versions < 3.4. This update will correct the undefined functions issues both of you ran into. Can you both please update to v1.7 and confirm/post back here if that corrected the issues you noticed? Thanks!!

    James

    Thanks! i will test this out today

    works like a charm! awesome work!

    Plugin Author James Mehorter

    @jamesmehorter

    Excellent! Thanks Dionte247 😀 Have a great day.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘[Resolved] [Plugin: Device Theme Switcher] Undefined Function’ is closed to new replies.
Skip to toolbar