• Resolved 123458emre

    (@123458emre)


    Hi all!

    I have a website that runs steady. There is no problem but on theme files. For example, when go to ‘site.com/wp-content/themes/theme1’ (index.php) or another theme files it gives an error like this: “Fatal error: Call to undefined function….” And I delete the “undefined” function. It still continues. I delete the other “undefined” functions until there is no php code in file. It’s valid for all themes, and theme files. Although these fatal errors seems, the website be still working. I tried to remove and to reinstall the plugins. However, website is still in the current situation.

    Thanks

Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter 123458emre

    (@123458emre)

    In addition, I use these plugins:

    add-to-any
    akismet
    all-in-one-seo-pack
    all-in-one-wp-security-and-firewall
    facebook-like-box-widget
    social-networks-auto-poster-facebook-twitter-g (not active)
    user-role-editor
    wp-pagenavi
    wp-super-cache
    yet-another-related-posts-plugin

    It would help if you posted the entire error message.

    Upload a fresh copy of your theme, and the Twenty Fifteen theme (or another default WP theme of your choice. Disable all plugins, clear your browser cache, and see what you get. First try the 2015 theme, and if it’s ok, try with your active (fresh) theme.

    Thread Starter 123458emre

    (@123458emre)

    Still gives errors for all themes:

    Fatal error: Call to undefined function get_header() in C:\xampp\htdocs\www\wp-content\themes\twentyfifteen\index.php on line 17

    Fatal error: Call to undefined function has_nav_menu() in C:\xampp\htdocs\www\wp-content\themes\twentyfifteen\sidebar.php on line 10

    Fatal error: Call to undefined function language_attributes() in C:\xampp\htdocs\www\wp-content\themes\twentyfifteen\header.php on line 12

    But some theme files aren’t like above. For example twentyfifteen/content.php has no error.

    I have a website that runs steady. There is no problem but on theme files.

    If it runs properly, what makes you say there is a problem with the theme files?

    when go to ‘site.com/wp-content/themes/theme1’ (index.php) or another theme files it gives an error

    I’m not sure why you’re trying to navigate to theme files as if they were web pages. Or maybe you didn’t explain what you’re doing that gives these errors.

    index.php at your site’s WP root should bring you to your site. If you’re trying to modify your theme files, you should do that with a text editor or in your admin edit panels (and preferably only in child themes). Changes you make to default or downloaded themes will be lost when they receive updates. Maybe I’m missing something?

    Thread Starter 123458emre

    (@123458emre)

    thanks for your patient.

    I mean, is it normal? Shouldn’t I find strange when I navigate to theme files and see these errors? Even the functions run

    The contents of a theme folder are, for example: functions, css styles, templates for different types of page layouts (like single posts, archives, search, etc,), and many are just parts of a page (like footer, header, sidebar, etc). Most of those don’t contain everything a page needs to display properly, so they can’t. Functions throw errors if everything doesn’t come in just the right order. WordPress knows how to put it all together, so you can’t just navigate to a file with a web browser out of order and expect it to work.

    As I mentioned above, if you want to see what’s in those files and folders, use your operating system’s directory browser, a text editor, or WP admin’s edit panel. And again, if you make changes, only do it on a child theme (as above). Does that help?

    Thread Starter 123458emre

    (@123458emre)

    Thanks

    Thread Starter 123458emre

    (@123458emre)

    .

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘Fatal Errors on theme files’ is closed to new replies.