WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Broken after upgrade add_rewrite_tag / taxonomy (25 posts)

  1. mbeam
    Member
    Posted 4 years ago #

    Ran the upgrade via the dashboard , everything seemed to go fine , went to click a link ( any link ) ,

    Fatal error: Call to a member function add_rewrite_tag() on a non-object in (editedout by me ).../taxonomy.php on line 289

    2 site's now down till i find a fix

  2. jhiner1978
    Member
    Posted 4 years ago #

    Im having the same issue..... Whats the solution

  3. mbeam
    Member
    Posted 4 years ago #

    Not sure what all this will affect but,
    I commented out lines 289 & 290 in taxonomy.php and the site came back up , still waiting on a official fix however .

  4. mbeam
    Member
    Posted 4 years ago #

    just disabled all plugins and removed comments from 289 & 290 and the site still w orks witch seems to point to a bad plugin being the culprit

  5. mbeam
    Member
    Posted 4 years ago #

    Upon further investigation ,
    The plugin that caused my crash was Podcasting Plugin by TSG

  6. FelipeGlauber
    Member
    Posted 4 years ago #

    Yes, mbeam, the Plugin that's causing this crash is Podcasting Plugin by TSG.

    You can recover original taxonomy.php file without make any change, that will be fine, your site will be back again.

    Thanks!

  7. FelipeGlauber
    Member
    Posted 4 years ago #

    Step by step to solve problem:

    Just do this, don't change nothing in "taxonomy.php" file, it's not necessary.. mbeam done this to discover what was causing the crash.

    1 -- Move (cut and paste) out the "podcasting" folder from "wp-content/plugins" folder

    2 -- Access your site normally, again. It'll be fine.

    3 -- Access your WordPress admin dashboard/panel.

    4 -- Go to plugins and check out the red message/alert on top warning that "podcasting.php" is disabled due to a file missing, itself.

    5 -- Move back the podcasting folder to plugins folder again, and it will return disabled.

    6 -- Wait for a compatible version to update it and activate it again.

    Cheers

  8. ddarby14
    Member
    Posted 4 years ago #

    Hey everyone, I don't recommend changing the WP code (taxonomy.php) as that may break other plugins/functionalities.

    I checked out this plugin and the offending line I found was line 15 in /plugins/podcasting/podcasting.php

    register_taxonomy('podcast_format', 'custom_field');

    I changed this to a function call

    function build_taxonomies() {
    	register_taxonomy('podcast_format', 'custom_field');
      }
      add_action( 'init', 'build_taxonomies', 0 );

    and the plugin worked perfectly for me. Hope this helps, looks like a great plugin.

    Let me know if this works.

  9. jdbausch
    Member
    Posted 4 years ago #

    ddarby14 - this appears to work for me. thank you!

  10. ddarby14
    Member
    Posted 4 years ago #

    np, glad to help - author has made this fix in official update so anybody else can just update the plugin for the 3.0 fix

  11. messel
    Member
    Posted 4 years ago #

    This could negatively affect the podcast plugin developer.

    Was it a wordpress change with unintended consequences or an error on the pluggin developers part?
    I see an action is added to call a wrapper function for one fix.

    At least for my blogs I deactivated and deleted all the podcast plugins instead of fixing/patching them.

    Having the blog down creeped me out a little this am.

  12. w2aiq
    Member
    Posted 4 years ago #

    well I have tha same problem, and I dont have the podcasting plugin!...it happens when I try to re-enable ANY plugin...I'll just have to go back to 2.9 I had a funny feeling about upgrading this time too!...gotta learn to follow my gut!

  13. christopherbaan
    Member
    Posted 4 years ago #

    Hi,

    I have the same problem, an don't have a podcast plug-in either. Any other plug-in that might cause this problem?

    Thanks

  14. danishjalbani
    Member
    Posted 4 years ago #

    I done have podcast installed

    I comment the line 289 and 290 in taxanomy.php so my site goes up

    But my admin panel is not going up and giving this fatal error

    Fatal error: Call to undefined function wp_unregister_globals() in /home/imrannas/public_html/wp-settings.php on line 35

    I tried commenting out these lines as well, I tried moving some plugins as well but nothing worked...

    Kindly help

  15. YorkshireLad
    Member
    Posted 4 years ago #

    I'm not using the podcasting plugin either. I do have the following installed (* means deactivated - I only use some plugins for some of the time):

    admin-menu-editor
    akismet
    cryptx
    donate-plus *
    eg-attachments
    embed-iframe *
    facebook-like-button
    media-tags
    news-ticker
    our-progress *
    peters-date-countdown *
    posttabs
    si-contact-form
    tinymce-advanced
    tinymce-excerpt
    user-photo
    wikistyle-autolinks
    wordpress-mobile-edition
    wordtube
    wp-dbmanager
    wp-google-weather *
    wp-page-numbers
    wp-task-manager *
    wplistcal
    hello.php *

    Some of them need updating, which I was going to do after the automatic upgrade - except I now can't access anything in the back-end. So all I can do now is remove all the plugins and re-add them one at a time...

    Gary

  16. riseandshine
    Member
    Posted 4 years ago #

    I had the same problem. But I did not have the podcasting plugin. In my case, the error was caused by WP-Ecommerce

  17. YorkshireLad
    Member
    Posted 4 years ago #

    Well... backed up the plugins directory, deleted everything except Akismet, Hello Dolly and index.php. Have added all the plugins I was actually using and so far no 'Fatal error' message. I did get the following though, when I re-added WordPress Mobile Edition:

    The plugin generated 490 characters of unexpected output during activation. If you notice “headers already sent” messages, problems with syndication feeds or other issues, try deactivating or removing this plugin.

    Gary

  18. YorkshireLad
    Member
    Posted 4 years ago #

    Also, Wikistyle Autolinks no longer does anything - it's activated, the options are as they were, but no links are generated. Just about to email the author.

    Gary

  19. krypton1
    Member
    Posted 4 years ago #

    I didn't have the Podcasting plugin installed either but may have in the past. I guess this plugin modifies your taxonomy file?

    Anyhow, here is what I did to solve it:

    1. commented line 289 and 290 from wp-includes/taxonomy.php to bring site back up
    2. moved taxonomy.php to taxonomy.php.old
    3. created a new taxonomy.php based on a fresh download of WordPress 3.0

    Seems to all be working now.

  20. january12
    Member
    Posted 4 years ago #

    I got the same problem as everyone else BUT I don't have any of the discussed plugins installed.

    The strange thing is that I only have 90 lines in my taxonomy.php but I still get the error being on line 289...

    In this case the problem was solved after first moving all the folders for a number of plugins to a dump folder and make sure the site worked and then move them back one by one to discover which ones work and which ones doesn't.

    It appears that the Mailpress plugin caused the Taxonomy.php error, but also Events-calendar caused another error when moved back, so I just left it in the dump folder.

  21. jarvisteam
    Member
    Posted 4 years ago #

    DDarby's solution worked for me as well. Surprised how easy it was to fix I have no PHP knowledge.

  22. Tashty
    Member
    Posted 3 years ago #

    Yup there's definately a conflict with wp-ecommerce plugin. My solution was the following once receiving the error "UPGRADE Fatal error: Call to a member function add_rewrite_tag() on a non-ob taxonomy.php" is to comment out the lines in taxonomy.php 289 and 290 like so // infront of each line. My site then whent back online. I deactivated all the plugins and I switched my permalink settings in the settings panel of wordpress back to default structure. I then made sure I had upgrade the e-commerce and any other plugins that needed upgrading, deactivated them again. I then uncommented the lines, reuploaded the taxonomy.php and reactived all the plugins and received no error. I have experienced unsual warnings and found that whilst making certain changes it's best to head back to default permalink structure, make your changes and then revert to custom structure.

  23. pcmedix
    Member
    Posted 3 years ago #

    I don't have the taxonomy plugin either. My error message is different ... "Fatal error: Call to a member function add_rewrite_tag() on a non-object in /home/asthmapt/public_html/wp-includes/taxonomy.php on line 289". It's in the includes folder. I tried renaming it to taxonomy-old.php, but that made things worse.My site is at . I'm not really experienced with php but this has to be an easy fix. Has anyone else had this same error?

  24. mr.goose
    Member
    Posted 3 years ago #

    One of my sites also produced the Fatal error: Call to a member function add_rewrite_tag() on a non-object in /var/www/my-wordpress-site/taxonomy.php on line 289 error.

    I took a different approach to fixing it. I upgraded to v3.1 alpha via SVN (trunk). This immediately fixed the problem. No code hacks and no plugins removed/edited etc.

    Kinda suggests that the underlying problem is with WordPress 3.0.1 itself - or perhaps the rather unfortunate way it handles plugins that it dislikes?

    More about SVN:-
    http://codex.wordpress.org/Installing/Updating_WordPress_with_Subversion

    Please note:- You need shell access to your server in order to use SVN. But it is worth getting you head around because it saves a lot of hassle when you need to upgrade (or install) - particularly if you are running several WordPress sites.

    I hope this helps someone. Best wishes, G.

  25. lkraav
    Member
    Posted 3 years ago #

    wp-e-commerce was the culprit for me, going from 2.9.2 -> 3.0.2.

Topic Closed

This topic has been closed to new replies.

About this Topic