when I enqueue a css for ui jquery accordion, media gallery is lost

  • Unknown's avatar

    The website is http://www.nirvanabymoto.com/blog
    The blog is a wordpress blog hosted through yahoo.
    I’ve placed an accordion panel on a custom page, using a child theme for 2014.
    However, when I enqueue the script that calls the css I want to use for the accordion panel, I can no longer view any images in my media gallery, nor will the page display after I update, publish, etc.
    I’ve placed the following code in the child themes functions folder:
    <?php
    function my_scripts_method() {
    if ( !is_admin() ) {
    wp_enqueue_script(‘jquery-ui-accordion’);
    wp_enqueue_script(
    ‘custom-accordion’,
    get_stylesheet_directory_uri() . ‘/js/accordion.js’,
    array(‘jquery’)
    );
    wp_register_style(‘jquery-custom-style’, get_stylesheet_directory_uri().’/css/jquery-ui-1.10.4.custom.css’, array(), ‘1’, ‘screen’);
    wp_enqueue_style(‘jquery-custom-style’);
    }
    }
    add_action(‘wp_enqueue_scripts’, ‘my_scripts_method’);
    ?>

    I’ve narrowed it down to the enqueue style as the culprit – and I’ve spent hours trying to figure out how to fix it but can’t seem to get it right. (I’m also very, very new at this)
    Any help you could throw my way would be GREATLY appreciated. Thank You!

  • Unknown's avatar

    The site you are asking about does not seem to be hosted on WordPress.COM so you need to make friends over at WordPress.ORG the keepers of the software you are using.

    https://en.forums.wordpress.com/topic/7-things-to-know-before-posting-in-wordpresscom-forums?replies=1

    This site is for support of sites hosted on WordPress.COM. You should address your questions to WordPress.ORG the keepers of the software you are using: http://wordpress.org/support/

    The forum at WordPress.ORG is not connected to WordPress.COM so you will need to open an account at .ORG if you do not already have one. You may use the same email at WordPress.ORG as you do at WordPress.COM.

    For more on the difference: http://support.wordpress.com/com-vs-org/

  • Unknown's avatar

    That is a WordPress.ORG blog, so head to their forums for help with that version of the software.

  • The topic ‘when I enqueue a css for ui jquery accordion, media gallery is lost’ is closed to new replies.