Support » Fixing WordPress » Unable to Log In and most pages have error

  • Resolved ozzieguy

    (@ozzieguy)


    Fatal error: Call to undefined function wp_initial_constants() in /home/xxx/public_html/xxx/wp-settings.php on line 33

    The front page and a couple of other pages load, however, I am unable to log in to do updates.

    Website http://www.beyondtools.com.au

Viewing 9 replies - 1 through 9 (of 9 total)
  • your foldirizing has problems. check that wp-settings.php

    Sorry, what is “foldirizing” has problems.

    I am very new to this sorry.

    What is it that I look for in the wp-settings.php?

    Lines 32 and 33 have this:
    // Set initial default constants including WP_MEMORY_LIMIT, WP_MAX_MEMORY_LIMIT, WP_DEBUG, WP_CONTENT_DIR and WP_CACHE.
    wp_initial_constants();

    Dipali Dhole

    (@dipalidhole27gmailcom)


    Some files are missing in the wordpress setup so this error occurs.
    wp_initial_constants() this function is undefined.This function is defined in the wp-includes/default-constants.php. Take backup of this file of your live site.
    Download fresh copy of wordpress.And upload this file from fresh copy to above location.

    Hope it will work.

    Thank you, I will try this

    I just checked that file by viewing the content and it is empty and many others are the same

    Dipali Dhole

    (@dipalidhole27gmailcom)


    Take a backup of all the site files & database.Replace wp-includes & wp-admin folder with fresh copy of wordpress.

    follow the below steps
    https://codex.wordpress.org/Updating_WordPress#Manual_Update

    Note:Do NOT delete your existing wp-content folder. Do NOT delete any files or folders in your existing wp-content directory

    Hope it will help.

    I did all of the above and now I have more problems.

    I cannot log in as Admin still, but now I have more and more errors.

    ERROR: Cookies are blocked or not supported by your browser. You must enable cookies to use WordPress.

    Plus these.
    Warning: include(/home/beyondto/public_html/wptools/wp-content/advanced-cache.php) [function.include]: failed to open stream: No such file or directory in /home/beyondto/public_html/wptools/wp-settings.php on line 65

    Warning: include() [function.include]: Failed opening ‘/home/beyondto/public_html/wptools/wp-content/advanced-cache.php’ for inclusion (include_path=’.:/usr/lib/php:/usr/local/lib/php’) in /home/beyondto/public_html/wptools/wp-settings.php on line 65

    Warning: Unterminated comment starting line 1 in /home/beyondto/public_html/wptools/wp-content/plugins/aio-shortcodes/sc/togglebox/short.php on line 1

    Notice: Undefined index: editor_image in /home/beyondto/public_html/wptools/wp-content/plugins/simple-responsive-slider/simple-responsive-slider-admin.php on line 227

    Warning: session_start() [function.session-start]: Cannot send session cookie – headers already sent by (output started at /home/beyondto/public_html/wptools/wp-settings.php:65) in /home/beyondto/public_html/wptools/wp-content/plugins/ninja-forms/ninja-forms.php on line 293

    Warning: session_start() [function.session-start]: Cannot send session cache limiter – headers already sent (output started at /home/beyondto/public_html/wptools/wp-settings.php:65) in /home/beyondto/public_html/wptools/wp-content/plugins/ninja-forms/ninja-forms.php on line 293

    Warning: Cannot modify header information – headers already sent by (output started at /home/beyondto/public_html/wptools/wp-settings.php:65) in /home/beyondto/public_html/wptools/wp-login.php on line 415

    Warning: Cannot modify header information – headers already sent by (output started at /home/beyondto/public_html/wptools/wp-settings.php:65) in /home/beyondto/public_html/wptools/wp-login.php on line 427

    Warning: Cannot modify header information – headers already sent by (output started at /home/beyondto/public_html/wptools/wp-settings.php:65) in /home/beyondto/public_html/wptools/wp-login.php on line 429

    Notice: wp_deregister_script was called incorrectly. Do not deregister the jquery script in the administration area. To target the frontend theme, use the wp_enqueue_scripts hook. Please see Debugging in WordPress for more information. (This message was added in version 3.6.) in /home/beyondto/public_html/wptools/wp-includes/functions.php on line 3049

    Well, by sheer accident I fixed the problem.

    Somehow, and who knows how, in the wp-config.php file I saw that it had “true” for debugging.

    I made it “false” and now everything works…

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Unable to Log In and most pages have error’ is closed to new replies.