• Resolved Paul Shryock

    (@paul-shryock)


    I am creating a new WordPress theme using Zurb Foundation, and the theme can currently be seen live here, while the code can be downloaded via GitHub here.

    When I run the theme on a local WordPress installation, it works great. When I upload the theme to a live WordPress installation, the Customizer doesn’t work, and widgets are not available in the Appearance menu.

    Does anyone know what is causing this and how it can be fixed?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Moderator Jose Castaneda

    (@jcastaneda)

    THEME COFFEE MONKEY

    Hi Paul!

    Taking a quick look at your github repo, I don’t see a customizer callback ( customize_register ) or a customizer file.

    As for the widgets not being displayed, are you using dynamic_sidebar() anywhere in the theme?

    Are some files missing?

    Thread Starter Paul Shryock

    (@paul-shryock)

    @jose thanks for the feedback. I will look into those issues and report back what I find. Much appreciated.

    Moderator Jose Castaneda

    (@jcastaneda)

    THEME COFFEE MONKEY

    Of course!

    If you aren’t already be sure to use the theme-check plugin to help you a little bit in your theme development.

    Thread Starter Paul Shryock

    (@paul-shryock)

    @jose,

    I don’t think I added the customizer callback yet, so that solves that problem.

    dynamic_sidebar() is used in index.php and some other page templates, so the widgets should be available, but still are not. I’ll see if the customizer callback fixes that issue.

    The only files I left out of this repo are some foundation javascript files which it’s not currently using anyway.

    Moderator Jose Castaneda

    (@jcastaneda)

    THEME COFFEE MONKEY

    Hey, Paul.

    Super odd your widgets are not showing. Try deactivating all your plugins. I can’t seem to replicate that on my local setup or a live site. :/

    Thread Starter Paul Shryock

    (@paul-shryock)

    I only have Theme Check and WP Example Content plugins active.

    I enabled Debug Mode, and visiting the dashboard shows Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_widgets_init' not found or invalid function name in /mywebsite/wp-includes/plugin.php on line 503.

    So clearly widgets aren’t being called, but I’m not sure why.

    Moderator Jose Castaneda

    (@jcastaneda)

    THEME COFFEE MONKEY

    Really odd, I don’t even see that being a callback on the repo.

    From the repo, the callback for the widgets_init is 'newtheme_single_post_sidebar' which does exist on line 38 of the functions file.

    Thread Starter Paul Shryock

    (@paul-shryock)

    I have a lot of work to do on this theme… mentioning the customizer callback really helped a lot. And using the Theme Checker plugin obviously highlighted many more areas I need to fix. I’m making slow progress here and there when I have time, but it will probably be a little while before I get to upload a more current version.

    I also don’t know GitHub very well, so I may have done something wrong with that repo. When I have something better ready, if you still want to see it, I’ll post a follow up with any questions I still have.

    Thanks a lot for your replies and help. 🙂

    Thread Starter Paul Shryock

    (@paul-shryock)

    @jose,

    I re-updated WordPress and that fixed the widget issue. It had nothing to do with the theme. Problem solved.

    If you’re interested, I’ve updated the theme on GitHub, and it’s getting close to being ready for some actual testing.

    My last hurdle is to add comments to singular.php. I also suspect I should change that file name to single.php.

    The Theme Check plugin throws 5 errors for things all related to comments, and I’m aware of those. But if you would like to look at the code for any other problems, I would love some feedback.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Creating theme, works fine locally, missing Customizer when live’ is closed to new replies.