Support » Plugin: Timeline Express » Plugin Class & Element Names

  • Resolved jumpstartcarrie

    (@jumpstartcarrie)


    Is it possible to rename the classes/elements that are prefixed with “cmb” as I have discovered that there is a conflict on certain themes (e.g. Tfingi) that utilise the Custom Metaboxes feature and also use the cmb prefix for their classes, functions etc.?

    I have had to manually do a bulk find and replace to get your plugin working with these themes, so it would be great if you could roll out a version with different naming conventions to prevent the conflict.

    Many thanks! 🙂

    https://wordpress.org/plugins/timeline-express/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Evan Herman

    (@eherman24)

    Hi,

    You’re issue is most likely related to your theme using an outdated version of the CMB class.

    I’ve had other users report conflicts with Timeline Express and a few other plugins using the CMB class. I originally had re-named and customized the CMB class file to prevent conflicts, which was what was causing the issue.

    Currently CMB is on a stable version 1.2.0. Do you know what version your theme is using?

    I’ve used the plugin along with other plugins and themes running CMB , nad have not had an issue. The class file only gets initialized if the class doesn’t already exist. So multiple plugins and themes running CMB should only ever initialize it one time.

    Thanks,
    Evan

    Thread Starter jumpstartcarrie

    (@jumpstartcarrie)

    Thanks for the extremely fast response!

    Looks like the latest version of the theme is still using version 1.0 of the CMB class, so as you point out, that could be the issue – results in a blank page when trying to edit content and a “Cannot redeclare class cmb_Meta_Box” error message (amongst others – all related to cmb elements) on the error log.

    Any thoughts as to how to resolve this?

    Plugin Author Evan Herman

    (@eherman24)

    Yea that’s what was happening with mine as well. I was using an older class in this plugin, and other plugins were using updated versions and there was a conflict.

    I wouldn’t be 100% sure but my best guess is to update the CMB class file and all the helper classes bundled with it. One issue I ran into, was that the newer versions had a different format for registering meta boxes so I had to re-write large parts of the plugin.

    That may be why the theme author hasn’t updated the CMB class in the theme. I would reach out to them and ask them what’s going on with the CMB class being outdated.

    Thanks,
    Evan

    Thread Starter jumpstartcarrie

    (@jumpstartcarrie)

    Ah, that’s a pain. It does seem a very distinct possibility that the theme author hasn’t updated the CMB class for the exact reason you state (I wish these things could be backwards compatible)!

    I can only hope that the theme developer is prepared to upgrade then, as otherwise I’m a bit stuck from the seem of things (which would be a shame, as this is a really nice plugin you’ve written).

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Plugin Class & Element Names’ is closed to new replies.