• I installed a new theme for my portfolio and it worked fine until I got this error:

    Warning: require_once(/home/deb62107/domains/jmvanoort.nl/public_html/wp-content/plugins/js_composer_theme/include/classes/shortcodes/vc-accordion.php) [function.require-once]: failed to open stream: No such file or directory in /home/deb62107/domains/jmvanoort.nl/public_html/wp-content/plugins/semona-extension/shortcodes/classes/accordion.php on line 13
    
    Fatal error: require_once() [function.require]: Failed opening required '/home/deb62107/domains/jmvanoort.nl/public_html/wp-content/plugins/js_composer_theme/include/classes/shortcodes/vc-accordion.php' (include_path='.:/opt/alt/php53/usr/share/pear:/opt/alt/php53/usr/share/php') in /home/deb62107/domains/jmvanoort.nl/public_html/wp-content/plugins/semona-extension/shortcodes/classes/accordion.php on line 13

    Do any of you have any tips/solutions on how to solve this?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi,

    Looks like the theme needs certain plugin for it to work. Can you check your theme’s documentation?

    Also, post a link to the theme’s official page.

    Dinsan

    @jmvanoort,

    tip 1) Please check directory for file exist or not. Or add using ftp for this location.

    tip 2) before require_once() function add “@” like @require_once() so remove warning on site.

    Thanks,
    Ravi patel

    Thread Starter jmvanoort

    (@jmvanoort)

    Both vc-accordion.php (js composer folder) and accordion.php (semona extension folder) exist.

    The line in accordion.php that the warning is about says:

    function sm_register_shortcode_handler_sm_accordion() {
    	if ( defined( 'WPB_VC_VERSION' ) ) {
    		require_once vc_path_dir( 'SHORTCODES_DIR', 'vc-accordion.php' );
    		class WPBakeryShortCode_sm_accordion extends WPBakeryShortCode_VC_Accordion {
    			function content($atts, $content = null) {
    				return sm_accordion_func( $atts, $content );
    			}
    		}

    Line 13 is: require_once vc_path_dir( ‘SHORTCODES_DIR’, ‘vc-accordion.php’ );

    I tried adding the @ that ravipatel suggested, but that didn’t change anything. I tried updating the PHP version, but that only resulted in a server error.

    Another weird thing is, I made a new WordPress page, installed the same theme and it’s working fine on there.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Warning: require_once’ is closed to new replies.