• Hi, I’m Bruno and am trying to get access to edit the source-code but it returns ERROR 500.
    I checked the logs and it said the error is on the file httpdocswp-includesclass-wp-theme.php on line 1152

    here is the code:

    foreach ( $results as $result ) {
    if ( ‘.’ == $result[0] || in_array( $result, $exclusions, true ) ) {
    continue;
    }
    if ( is_dir( $path . ‘/’ . $result ) ) { // this is the line 1152
    if ( ! $depth ) {
    continue;
    }
    $found = self::scandir( $path . ‘/’ . $result, $extensions, $depth – 1 , $relative_path . $result );
    $files = array_merge_recursive( $files, $found );
    } elseif ( ! $extensions || preg_match( ‘~.(‘ . $_extensions . ‘)$~’, $result ) ) {
    $files[ $relative_path . $result ] = $path . ‘/’ . $result;
    }
    }

    what should I do? I need this access to fix another thing. Thankyou so much!!

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator t-p

    (@t-p)

    Do you mean you are trying to edit the CORE file /wp-admin/theme-editor.php ?

    If so, first off, why do you want to edit the core file? Not a good idea.

    As the adage goes, don’t modify core files (unless you know what you are doing in there and are aware of the limitations and drawbacks this imposes). Modifications can cause:
    – security risks,
    – performance degradation,
    – broken plugins/themes,
    – you will lose all changes when you next update the WordPress, etc.

    Thread Starter neryes

    (@neryes)

    Thankyou for you reply!

    I need to install the php module SOAP.

    And the research I’ve seen, people told to edit some code.

    And when I click on “editor”, it returns the error I mencioned.

    Now I dont know what to do.

    Dion

    (@diondesigns)

    Installing PHP extensions is done at the server level and not from within WordPress. You should contact your hosting company and ask whether the SOAP extension can be installed.

    If you have unmanaged hosting, or if this is a localhost install, you will need to install the SOAP extension yourself. I’m sure that either your hosting company, or your localhost software support site, have some tutorials that explain how to do this.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Access to the theme-editor.php’ is closed to new replies.