• Resolved mrinternet

    (@mrinternet)


    1341 –> function wp_embed_defaults() {
    if ( !empty($GLOBALS[‘content_width’]) )
    $theme_width = (int) $GLOBALS[‘content_width’];

    $width = get_option(’embed_size_w’);

    if ( empty($width) && !empty($theme_width) )
    $width = $theme_width;

    if ( empty($width) )
    $width = 500;

    $height = get_option(’embed_size_h’);

    if ( empty($height) )
    $height = 700;

    return apply_filters( ’embed_defaults’, array(
    ‘width’ => $width,
    ‘height’ => $height,
    ) );
    }

    Above error prevents opening admin dashboard – site views OK on internet

Viewing 5 replies - 1 through 5 (of 5 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Which is line 1341? The very bottom of your file?

    If so, you’re missing an ending bracket

    Thread Starter mrinternet

    (@mrinternet)

    the top line is 1341…
    I added a bracket at last line as suggested and that created error message for that line – Parse error: syntax error, unexpected ‘}’ in /vvvv/xxxx/public_html/xxxx/wp-includes/media.php on line 1362

    Original error message for line 1341 (Top line)
    Parse error: syntax error, unexpected $end in /xxxx/xxxx/public_html/xxxx/wp-admin/includes/media.php on line 1341

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    What is above line 1341, could you post the function above?

    Thread Starter mrinternet

    (@mrinternet)

    line 1312/**
    * Register an embed handler. This function should probably only be used for sites that do not support oEmbed.
    *
    * @since 2.9.0
    * @see WP_Embed::register_handler()
    */
    function wp_embed_register_handler( $id, $regex, $callback, $priority = 10 ) {
    global $wp_embed;
    $wp_embed->register_handler( $id, $regex, $callback, $priority );
    }

    /**
    * Unregister a previously registered embed handler.
    *
    * @since 2.9.0
    * @see WP_Embed::unregister_handler()
    */
    function wp_embed_unregister_handler( $id, $priority = 10 ) {
    global $wp_embed;
    $wp_embed->unregister_handler( $id, $priority );
    }

    /**
    * Create default array of embed parameters.
    *
    * @since 2.9.0
    *
    * @return array Default embed parameters.
    line 1340 */

    Thread Starter mrinternet

    (@mrinternet)

    Error resolved by reinstalling WordPress 3.4.1
    I want to sincerely thank anevins for his gracious time and effort in resolving my error.

    This site has an extraordinary history of malicious attacks/hacks and there is always a new zeroday angle even though it has been hardened with every conceivable twist.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘includes/media.php – syntax error, unexpected $end line 1341’ is closed to new replies.