Support » Plugin: ReciPress » [Plugin: ReciPress] Catchable fatal error: Object of class WP_Error could not be converted to string

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Author Tammy Hart

    (@tammyhart)

    This happens when you have a blank ingredient line in your recipe. There will be an update later today that will fix this, but for now, you can open up php/functions.php and add this after line 201:
    if(!$ingredient['ingredient']) continue;

    Thanks for help but it is still same. I think I will wait update. Here is the code what I addedd

    if(!$ingredient[‘ingredient’]) continue;
    <?php foreach ($options as $value) {

    switch ( $value[‘type’] ) {

    case “open”:
    ?>
    <table width=”100%” border=”0″ style=” padding:10px;”>

    Plugin Author Tammy Hart

    (@tammyhart)

    ah, WordPress adds a line break to plugin and theme files. Search for foreach($ingredients as $ingredient) { and add it after that. You should wind up with this:

    foreach($ingredients as $ingredient) {
    	if(!$ingredient['ingredient']) continue;
    	$output .= '<li class="ingredient">
    ... etc ...

    I did it but still same 🙁

    Plugin Author Tammy Hart

    (@tammyhart)

    Is it doing that on every recipe, or just one or two? Can you check them to see if you have an empty ingredient entry? If you don’t, the problem has a different root.

    it is happen for all recipes. There is no empty ingredient. And everythings works good before wordpress 3.3 upgrade

    When update will be publish?

    Error still continue

    There is no changes after update

    Error still continue

    After last update 1.7
    Error line changed to 211

    Catchable fatal error: Object of class WP_Error could not be converted to string in ../mutfaktabirivar/wp-content/plugins/recipress/php/functions.php on line 211

    Line 211 in functions.php is

    $output .= ‘<span class=”name”>‘.$ingredient.’</span> ‘;

    Plugin Author Tammy Hart

    (@tammyhart)

    would you be willing to give me admin access so i can play directly with your installation? you could create a temp admin user and then delete once we’re finished. I had this error on another site and was able to fix it, but the fix isn’t working for you for some reason and I’d like to be able to dig in myself, rather than stab around in the dark.

    I emailed to you access information

    Thank you

    Plugin Author Tammy Hart

    (@tammyhart)

    For others that may be following this thread: the issue with monfree’s installation is that the turkish alphabet includes many special characters and thus breaks the get_term_link function. I am currently looking into a long term solution for this. Meanwhile, I’ve removed that function from his installation for now.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘[Plugin: ReciPress] Catchable fatal error: Object of class WP_Error could not be converted to string’ is closed to new replies.